How to open a PHP file

Source: Internet
Author: User
Tags php language php file php and php basics php code php open file what php

What is PHP:

PHP is the acronym for the English Hypertext preprocessing language hypertext preprocessor. PHP is a kind of HTML embedded language, is a server-side embedded HTML document script language, language style has similar to C language, is widely used.

PHP is a network of people often said backstage, used to deal with databases, and many sites are written in PHP, including, and other sites, are written in the PHP language. Our articles are uploaded to the server database via PHP code and then generated statically by PHP code.

How PHP files are opened:

Simple words php and txt (text document) like, Notepad can be opened, but see the code, not the effect of PHP implementation, such as we open the test.php code because the encoding has GBK or UTF8 format, with Notepad to open the UTF8 format of PHP files, When there is a Chinese time is garbled, so we recommend the use of Dreameweaver or editplus support UTF8 format files, such as software open. (ordinary user chooses editplus to open, because EditPlus is relatively small)

A section of PHP test code

Copy code code as follows:


For ($i =1 $i <=10; $i + +) {

echo $i. ' <br/> ';


echo "";


But the goal is often not want to see such code, if you want to see the effect after implementation, you need to configure the PHP operating environment.

We visit the are server-side preconfigured PHP operating environment, may be Linux may also be windows, we buy space when asked IDC business, asked them whether to support PHP, or later purchased not support PHP space, also can not support PHP.

If everyone is a local test of PHP code, you can use some tools such as Phpnow (Phpnow installation use is relatively simple, after installation will be copied to the php file Htdocs directory, in the browser input can, If a port is selected to be added to port Ports, IIS can, but requires a slightly more professional person to configure. Here we also provide you with the IIS PHP operating environment. The premise is that your computer has IIS, the general default PC is not installed, the operating system that supports IIS is generally a winxp,win2003 system.

If you set up the PHP operating environment, in the browser to enter the URL, you can see the operation of PHP (note: Everyone in the browser can be entered in the Web site is not the same, we this is the intranet IP)

A lot of friends without foundation, often ask PHP file how to open, in fact, PHP is a web script, but different from HTML XML tag language, can be opened directly through the browser, you need to have PHP to run the environment to access and open files, if just edit php open file, You only need to use Notepad or through the relevant editor such as (DW, eclipsephp, EditPlus, etc.) to open the edit.

Again to introduce what PHP is, add point php Basics, PHP, is the English hypertext preprocessing language hypertext preprocessor abbreviation. PHP is a kind of HTML embedded language, is a server-side embedded HTML document script language, language style has similar to C language, is widely used. Another implication of PHP is that the Philippine peso is a standard symbol.

When we study the website construction, the initial contact more certainly is the HTML language, the dynamic language certainly is the ASP. But with the development of the network, as well as the changes in the direction of the host, especially in the overseas host more Linux system, win system is very few, and very expensive. So forcing us to also choose Linux Host, using the PHP language program. Some friends ask questions, PHP language website how to open. This question is actually very simple, no matter what language Web page, we can use DW or EditPlus or Notepad to open.

But debugging PHP program is different from the ASP so simple, we can directly in the PHP space debugging or install the local environment, I now use Phpnow or wampserver, are a good tool.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.