Configure apache2.0.52 + php5.0.2 + mysql4.0.21 + perl

xiaoxiao2021-03-06  117

First, use software: apache_2.0.52-win32-x86-no_ssl php-5.0.2-win32 mysql-4.0.21-win phpMyadmin-2.6.0 Configuration Environment: Windows XP SP2 2, Specific steps Note: Installation process, any Don't use spaces, don't use D: / Program Files to use D: / programfiles 1. Apache_2.0.52-win32-x86-no_ssl apache server software, I downloaded WIN version, 2.0 series configuration It is similar. Double-click to install Apache2.0.52, I installed it to D: / ApacheGroup Note that the directory name does not include spaces, otherwise the PHP will be made wrong below. After the installation is over, the Apache is automatically running, enters http://127.0.0.1 in the browser, is it displayed by the default web page, if you don't want to see this page, you can go to D: / apachegroup / apache2 / conf directory Find httpd.conf to open editing, and find DocumentRoot "in version 2.0 series, only one documentroot", change the path in the quotation marks to your own path, such as DocumentRoot "D: / PHP" now default The root directory is D: / PHP Note that "/" is used here. 2, install php5.0.2 downloaded PHP-5.0.2-win32 is generally a zip format compression package, unzipped into the D: / ApacheGroup directory, and make the file under a folder, change the folder named PHP5 This is convenient for the next job. Now we see the D: / ApacheGroup, there is already two folders, one is apache2 (a folder installing Apache2.0.52 automatically generated) The other is PHP5, my way is a folder for each software, and these The folder is in the same directory so that it is easy to find.

Ok, we now start configuring apache to support php5. First, find the php.ini-dist of the D: / ApacheGroup / PHP5 directory to rename PHP.Ini and copy it to the C: / Windows directory, then copy D : / Apachegroup / php5 directory PHP5TS.DLL, libmysql.dll to c: / windows / system, let's start configuring the httpd.conf file under D: / ApacheGroup / Apache2 / confus, open httpd.conf (available Notes This Open) 1 Find the AddDefaultCharset ISO-8859-1 to change it to AddDefaultCharset GB2312 (let the default language encoding as Simplified Chinese) 2 Find DirectoryIndex index.html index.html.var Add index.htm index.php index.php3 - ------------- Modular installation configuration --------------------------------- --- Find this line in #LoadModule SSL_Module Modules / MOD_SSL.SO, add a line loadModule PHP5_Module D: /apachegroup/apache2/php5/php5apache2.dll in this line D: / ApacheGroup / Apache2 / PHP5 / for you PHP directory #Addencoding x-gzip .gz .tgz Add AddType Application / X-httpd-php .php .phtml .php .php .phtml .php3 .php4 is added to pHP.phtml.php3.php4 here's mainly Two, one is copying php.ini to the system disk, the other is to configure httpd.conf to support PHP5, here you require an absolute path, such as D: / ApacheGroup / Apache2 / PHP5 / middle can't appear space, otherwise apache2.0.52 Will go wrong! Ok, now you have already supported PHP now, huh, it is successful! 3, install MySQL-4.0.21-Win Because Apache is configured in the WIN environment, the mysql here is also WIN version. After decompression, install mysql4.0.21 to d: / apachegroup / directory, and make MySQL completely installed into the mysql directory (you can select the folder name of the installation path), ok, Mysql has no specific requirements, mainly It is the next configuration. First start mysql (if you have not used it to start, look at the taskbar has no little green lights), then let me, now my mysql is already installed to the D: / apachegroup / mysql directory, then enter D : / Apachegroup / mysql / bin Find winmysqladmin.exe double-click, MySQL automatically starts running. All right. Start configuring php.ini.

Enter C: / Windows Open PHP.INI to find extension_dir = "./" change to extension_dir = "d: / apachegroup / php5 / ext" found; extension = php_mysql.dll will ';' remove it to extension = php_mysql.dll session.save_path = "/ tmp" will ';' Remove the directory of setting you to save the session, such as session.save_path = "d: / apachegroup / php5 / session_temp"; ok, it has been successful here! 4, PHPMYADMIN-2.6.0 Configuration Unfaze phpMyAdmin-2.6.0.zip into your defined web root directory, rename folder to phpMyAdmin or other Config.inc.php in the phpMyadmin directory to find $ CFG [ 'Servers'] [$ I] ['user'] = 'root'; $ cfg ['servers'] [$ I] ['password'] = '123456'; fill in your MySQL user and password Super practical supplement: 1. PHP.INI Configure register_globals = ON Some programs require this support, otherwise you can't upload files 2. Prohibit all of the directory Remove all indexes to remove the user will not see the directory list 3, set the virtual directory Edit the httpd.conf file, plus a line of alias / test / "c: / php / test /" in this file, allowing to browse specific virtual directories Alias ​​/ Test / "D: / PHP / TEST /" OPTIONS INDEXES FOLLOWSYMLINKS Write the above code to httpd.conf Wen dynasty Description: Line 1: Mapping Virtual Directory TEST to Real Physical Path D: / PHP / TEST Line 3: Options INDEXES FOLLOWSYMLINKS Allows the file 5 under the virtual directory TEST, a point about the global configuration of Apache2.0.52 ServerAdmin Webmaster@****.net is set to the administrator's email address servername www. ****. Net: 80 host name (domain name, IP address can be) and port address DocumentRoot "D: / PHP" website root directory DirectoryIndex index.php index.html index.htm index.php3 index.html.var Add to default document ServerToKens Full display server information, Full is all, PROD For the least, it is recommended to set it to the prod, not easy to expose the server information addtype application / x-httpd-php .php .phtml .php3 .php4 join the support for PHP, PHTML, PHP3, and PHP4 files, big work, huh, huh, good Celebrate! Van Xing 2004-10-22 Q Q: 14188256 Tight the above setting: Apache Advanced Additional Function:

1. Configure ActivePerL-5.8.4.810-MSWIN32-X86 (to support CGI / PL) Double-click Download ActivePerl-5.8.4.810-mswin32-x86.EXE installation to D: / ApacheGroup / Perl Directory (preferably to C) : / usr) In order to facilitate file management, I installed Perl to the D: / ApacheGroup / Perl directory. Let's start setting up httpd.conf to make CGI / PL work properly: (1) Looking for addHandler CGI-script .cgi, add .pl, addHandler cgi-script .cgi .pl (2) If you want to add SSI, you need to put the following Several lines of the ## (no yourself added). AddType text / html .shtml addoutputfilter incruds .shtml addhandler server-pased .shtml also pay attention to the Perl interpretation path in the Perl script, you must put the default #! /Usr/perl/bin/perl.exe of all CGI or PL file headers (Perl.exe) Change to #! D: /apachegroup/perl/bin/perl.exe (ie your own perl.exe is located, so server can find the Perl compiler), if you use C: / usr The directory installation does not need to be changed, and it is strongly recommended that ordinary users install Perl in the C: / USR directory. The directory where the CGI / PL is located below is to be browsed, so it can be correctly parsed. Here is a directory where Perl.exe is located, installing in a C: / USR directory, can reduce a lot of unnecessary settings (for example, setting up each CGI / PL file header #! / Usr / perl / bin is of course also You can use UltraEdit32 to make batch changes, I am doing this!) Directory Security Settings: Find Find Figure Options None Allowoverride None # All section is set to global settings, that is, all Directory browsing. # Allow a specific directory to browse. It is important to set the correct to run the NONE of the CGI / PL # on the red word part of the CGI / PL # indicate that all directory browsing, if ALL is to allow directory sharing # to see. To make CGI / PL, you must browse, such as my PHP file in D: / PHP / ZLD / directory, as long as this directory allows browsing, the file header is correct. Displays the CGI page.

转载请注明原文地址:https://www.9cbs.com/read-100070.html

New Post(0)