How to open the php file. What is php: PHP, short for HypertextPreprocessor, an English super Text preprocessing language. PHP is an embedded HTML language. it is an embedded HTML document that is executed on the server.
What is php:
PHP is short for Hypertext Preprocessor. PHP is an embedded HTML language. it is a scripting language that executes HTML documents embedded on the server. it is widely used in a style similar to C language.
Php is the background commonly used in the network. it is used to process databases. many websites are written in php, including www.baidu.com and www.jb51.net, which are all written in php. All of our articles are uploaded to the server database through php code, and then generate static data through php code.
How to open the php file:
In a simple sentence, php is the same as txt (text document). you can open it in Notepad, but you can see the code instead of the php execution result. for example, we can open test. php code is encoded in gbk or utf8 format. when you use notepad to open a php file in utf8 format, garbled characters occur when there is a Chinese character, therefore, we recommend that you use software such as dreameweaver or editplus that supports utf8 files. (Select editplus for normal users, because editplus is relatively small)
Php testing code
The code is as follows:
For ($ I = 1; $ I <= 10; $ I ++ ){
Echo $ I .'
';
}
Echo "www.jb51.net ";
?>
However, you often do not want to see such code. if you want to see the execution result, you need to configure the php runtime environment.
Www.jb51.net is a php runtime environment configured on the server side. it may be linux or windows. when purchasing a space, you can ask the idc vendors to check whether they support php, otherwise, I purchased a space that does not support php and cannot support php.
If you are testing php code locally, you can use some tools such as phpnow (phpnow is easy to install and use. after installation, copy the php file to the htdocs directory and enter http in the browser: // 127.0.0.1. if you select a port, you can add the port http: // 127.0.0.1: port number) to iis. However, you must be a professional user. Here we also provide you with the iis php runtime environment. The premise is that you have iis on your computer. by default, it is not installed on your PC. the OS that supports iis is generally winxp or win2003.
If you have set up the php runtime environment and enter the Web site in the browser, you can see the running effect of php (note: The Web site entered in the browser may be different. We use an intranet ip address)
Many friends without a foundation often ask how to open the PHP file. In fact, PHP is a web page script, but unlike the html xml tag language, it can be opened directly through a browser, you must have a PHP runtime environment to access and open the file. if you only need to edit PHP to open the file, you only need to use notepad or use relevant editors such as DW, EclipsePHP, and editplus) click edit.
Next we will introduce what PHP is and add some basic PHP knowledge. PHP is short for Hypertext Preprocessor. PHP is an embedded HTML language. it is a scripting language that executes HTML documents embedded on the server. it is widely used in a style similar to C language. Another meaning of PHP is the standard symbol of the Philippine peso.
When we were learning about website construction, most of our initial contacts must be the HTML language, and the dynamic language must be ASP. However, with the development of the network and the change of the host direction, especially the LINUX system, which has a large number of hosts outside China, Windows systems are rare and expensive. Therefore, we are forced to select a LINUX host and use a PHP program. Some friends asked how to open a PHP website. This problem is actually very simple. no matter what language web pages are used, we can open them with DW, EDITPLUS, or notepad.
However, debugging PHP programs is not as simple as ASP. we can directly debug or install the local environment in the PHP space. the PHPNOW or wampserver I am using is a good tool.
Short for Hypertext Preprocessor. PHP is an embedded HTML language. it is an embedded HTML document executed on the server...