Build PHP's Local debugging environment _php tutorial

Source: Internet
Author: User
For the Windows platform, PHP provides an installer, but the installer cannot be run directly to build a personal server platform, but must be embedded in an existing server platform, such as Windows NT under IIS or PWS under Windows, and Apache. Based on my own experience, I wrote out the process of setting up a PHP debugging environment based on the personal server platform of PWS, hoping
You are the expert to give advice.
Before the installation, download the PHP installation program under Windows, the new version is currently 4.0, on a large web site are downloaded. Really can't find, can directly to PHP site Http://www.php.net download, in that, can get updated information. The downloaded file is a compressed package, generally named: Php-4.0.x-win32.zip,x represents the version number, you can see the corresponding version, of course, the newer the better. Unzip it into the c:php directory (as explained in 3rd below) and you can see that the directory contains all the files that PHP needs.
The preparation is ready, and you can start the real installation below. First of all, needless to say, the first installed Microsoft's PWS, and set the various parameters of PWS and related network settings, specific can see the relevant information, I say, you may say that I cheat. After installation, it is better to test first, otherwise, the following work is white. Below, a few steps to embed the PHP installation.
1. Into the c:php folder, you can see some *.dll files and other related files, the DLL files that start with PHP_ can be kept in c:php, other DLL files must be copied to the system's search path, the more commonly used is the C:windowssystem folder.
2. Find in the c:php folder named Php.ini-dist (no extension), change the file name to PHP.ini, open the file with Notepad, you can see the inside is the PHP system configuration information, specific information to examine the explanation inside. But it is in English, it will cost brains more. After the corresponding information has been modified, copy the php.ini into the C:windows folder and take care to remove the read-only attribute.
Using Registry Editor to open the registry, follow the following path to indicate the key value: Hkey_local_machinesystemcurrentcontrolsetservicesw3svcparametersscript Map in this key value, Create a new String value: ". php" Data is "C:phpphp4isapi.dll" (note: the path corresponding to the Php-4.0.x-win32.zip compressed files extracted to the directory, if you unzip the directory and my inconsistency, please make the corresponding changes), to this, PHP file settings are basically complete, the following should be set PWS, so that it can explain the PHP script. Open PWS Personal Web Manager, click Advanced, virtual directory tree, right-click the directory that needs PHP support, I select PHP, select "Properties", in the pop-up "Edit directory" window, in the "read", "execute", "script" three check box tick, click "OK" exit. Two.
5. Restart the computer, OK, you are done, your server platform is built.
When debugging a PHP script, put the corresponding *. It is important that the PHP file is placed in a virtual directory with Execute permissions (that is, the directory set in step 4th), and that it does not explain PHP scripts to other directories that do not have permission to execute. Below can open IE browser, enter the file name of PHP script in the Address bar, method and open ASP script method is the same, except the script file extension is PHP, and ASP extension is ASP. such as: In the C:inetpubwwwroot php directory, (PHP directory is set in the fourth step with the corresponding execution permissions of the directory) has a script file named: 1.php, then you can enter in the address bar of IE: HTTP://192.168.0.1/PHP/1. PHP, you can see your own programming, is there a sense of success?

http://www.bkjia.com/PHPjc/532633.html www.bkjia.com true http://www.bkjia.com/PHPjc/532633.html techarticle for the Windows platform, PHP provides an installer, but the installer cannot be run directly to build a personal server platform, but must be embedded in an existing server platform ...

  • 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: info-contact@alibabacloud.com 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.