Win2003 installation software PHP5 Graphics installation Tutorial _win server

Source: Internet
Author: User
Tags php and
This article discusses the installation of PHP5 under WINDOWS2003, please note

    Download PHP5, download address: http://www.php.net/downloads.php, after the site opened as shown in the following figure, there are several versions of the choice, because the operating system is Windows2003, so we choose the version under Windows binaries , there are two versions: one is a zip version, the other is an installation version. This article discusses setting up a server environment, so select the zip version. Click "PHP 5.2.12 Zip package" To download the PHP installation file.
    The official web site is now php5.2.13 version and cannot be used in ISAPI format, so you can download the PHP 5.2.12 Version from the cloud community.

    Select the download mirror, choose whichever, click Start Download.



    After downloading, the PHP installation package is extracted to the disk directory, the general also set to the non-system disk, the author set is "D:\Program\PHP"

    Get the unpacked file

    Modify the "php.ini-dist" file name to "php.ini" and copy it to the Windows installation directory "C:\Windows"


    Registers the Egpcs (environment,get,post,cookie,server) variable as a global variable. Turn on "php.ini", find "register_globals = off", modify to "register_globals = on", and turn off the error message. Open "PHP.ini", find "display_errors = on", modify to "display_errors = Off", and set extension position. Open "php.ini" and find "Extension_dir =./", this article takes extension file in "D:\Program\PHP\ext" as an example, so modify the line to "Extension_dir =" D:\Program\ Php\ext\ ""; Let PHP support the GD library. Open "PHP.ini", find "; Extension=php_gd2.dll", remove the front semicolon, and let PHP support the MySQL database. Open "PHP.ini", find "Extension=php_mysql.dll", remove the front semicolon, and open mbstring to support phpMyAdmin. Open "PHP.ini", find "; Extension=php_mbstring.dll", remove the first semicolon, and other modules can add support freely on request, as above, remove the semicolon before the extenstion= module. dll; Libmysql.dll "and" Php5ts.dll "to the system directory" C:\Windows\system32 "


    Set up IIS to have IIS support PHP. The CGI and ISAPI two modes are supported when PHP is consolidated with IIS, the ISAPI mode is efficient, the performance is good, the stability is slightly worse, the CGI mode is the opposite. Typically, the ISAPI mode is first, and the problem is replaced by the CGI mode. It is recommended that you use ISAPI mode. The ISAPI mode installation method is described below
    Open Internet Information Services (IIS) Manager, expand the left side, right-click on the Web Site tab, select Properties, and open the Site Properties dialog box;

    Click the "ISAPI Filter" tab, click "Add", open the Add/Edit Filter Properties dialog box, filter name fill out "PHP", the executable file select "Php5isapi.dll", the file is located in the root directory of PHP directory, add finished click "OK" confirmation;

    Click on the "Home Directory" tab of the "Site Properties" dialog box and click "Configure" under "Home Directory".

    Open the Application Configuration dialog box and click Add to open the Add/Edit Application Extension Mappings dialog box;

    "Executable" still selects the Php5isapi.dll in the root directory of the PHP installation directory, and the extension is set to "PHP."

    The PHP support setting ends and the Internet Information Services (IIS) Manager is closed. Restart IIS, open Internet Information Services (IIS) Manager again, and view the ISAPI filter option, where you can see an extra item in the filter, as shown in the following illustration:

    Add a default document. Open Internet Information Services (IIS) Manager, expand the left side, right-click on the Web Site tab, select Properties, open the Web Site Properties dialog box, and select the Documents tab;

    Click "Add", enter "index.php" in "Default content page", click OK, continue to click "Add", enter "default.php", click OK. Add IIS to support index.php and default.php as default documents; the previous PHP support has been set up, but the PHP file cannot be accessed at this point because Windows2003 introduced a new security mechanism and needed to set up a Web service extension.
    Open Internet Information Services (IIS) Manager, expand the content on the left, right-click on Web service extensions, and select Add a new Web service extension;

    To enter "PHP" in "extension", ask the file to select the Php5isapi.dll that is located in the root directory of the PHP installation directory, and then select the "Set extended status to Allow" checkbox and click OK to close the dialog box.

    Now you can make a probe test, create a file named "php.php" in the IIS root directory, open it in Notepad, and enter
    <?php
    Phpinfo ();
    ?>
    Save, open "http://localhost/php.php" in the browser, and you should display the following figure

    PHP installation completed.

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: 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.