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

xiaoxiao2021-03-06  113

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 already have two folders, one is apache2 (a folder installing Apache2.0.52 Automatically generated) The other is a PHP5 my way is a folder for each software, and these files The clip 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 the #LoadModule SSL_Module Modules / MOD_SSL.SO this line, add a line loadModule php5_module d: /apachegroup/apache2/php5/php5apache2.dll after this line D: / apachegroup / apache2 / php5 / for your php directory, Locate AddType Application / X-gzip .gz .tgz, add a line of addtype application / x-httpd-php .php after this line ------------------------------------------------------------------------------------------------------------ ------------------------------------- ------- CGI installation configuration -------------------------------------- Find AddType Application / x-gzip .gz .tgz This line is added to scriptalias / php / "d: / apachegroup / apache2 / php5 /" addtype application / x-httpd-php .php action Applicatio N / X-httpd-php "/ php-cgi.exe" 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 ask Among the absolute paths, such as D: / ApacheGroup / Apache2 / PHP5 / inner can't have spaces, otherwise Apache2.0.45 will be 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 Configuration Register_global = ON Some programs require this support, otherwise it will not be uploaded. 2. Prohibit the browsing directory Remove all indexes to remove the user will not see the directory list 3, edit httpd. Conf file, plus a line in this file alias / test / "c: / php / test /" 4. Allow Browse specific virtual directories Alias ​​/ Test / "D: / PHP / TEST /" Options Indexes FollowSymlinks Write the above code to httpd.conf text Description: Line 1: Mapping Virtual Directory TEST to Real Physical Path D: / PHP / TEST Line 3: Options INDEXES FOLLOWSYMLINKS Allow Browse virtual Directory Test's file 5, a 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) and port address Documentroot "D: / PHP" website root root directory directoryindex index.php index.html index.htm index.php3 index.html.var Add to the default document ServerToKens Full display server information, FULL is all, PROD is the least, It is recommended to set it to the PROD, which is not easy to expose the server information addtype application / x-httpd-php .php .phtml .php3 .php4 join the support for PHP, PHTML, PHP3, PHP4 file, big merit, huh, huh, I will celebrate some ! 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. Start setting httpd.conf to automatically convert D: / apachegroup / apache2 / cgi-bin directory to virtual directory (preferably put the CGI program in this directory, if the picture does not display properly, please restart the computer, after restart The problem, or the CGI program can be placed under the root directory. After testing, put it in the root directory, the picture is also displayed normally.) (1) Looking for , there is an options in the next parameters Add an all, pay attention to the case. There is an ALOWOVERRIDE again, and also removes the back of None, add an all (2) to find , there is an Options in the eighth line of the next. Turn off the back of the parameters, add an all, pay attention to the case. There is an ALOWOVERRIDE in the lower number, and also removes the None behind, add an all (3) to find #Scriptalias / cgi-bin / "d: / apachegroup / apache2 / cgi-bin /", remove the front ## (4) Looking for There is an allowoverride below, remove the back parameters, add an all, pay attention to the case. There is another option to remove the None behind, add an all (5) to find the addHandler cgi-script .cgi, add .pl, addHandler cgi-script .cgi .pl (6) If you still want to add SSI, Need to remove the ## in front of the following two lines.

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

New Post(0)