Windows 2003 build Apache PHP MySQL environment experience sharing

  

This article is built on windows2003, the software version is Apache2.2.6 (Win32), PHP5.2.4, MySQL5.0.45, phpMyAdmin2.11.1. Apache and MySQL need to be installed, PHP and phpmyadmin are both decompressed and configured.

The detailed installation process is not to say, go to the Internet to search for a large piece, here is just to talk about a few problems I encountered during the construction process, so that everyone has a reference to the same problem.

1, PHP directory php5ts.dll and libmysql.dll to be copied to the system32 directory of the system.

2, php.ini copied to the windows directory, the previous version is not clear, but I did not copy php.ini to the windows directory, directly rename php.ini-dist in the php directory. Of course, in the Apache httpd.conf configuration file, add a line of PHPINIDir c: /php /php.ini (my PHP is installed in the C disk PHP directory).

3, Apache appears 403 denied access error In the httpd.conf file, modify DocumentRoot "I:/blog"

according to the directory of your website 4, how to make the .htaccess file work Apache defaults to .htaccess not working. If you want .htaccess to work, you need to modify the httpd.conf file to find a single line of llowOverride none in the file, and modify it to AllowOverride All or AllowOverride fileinfo.

5, before using phpmyadmin, remember to modify the config.inc.php (this file is renamed by config.sample.inc.php) $cfg['blowfish_secret'] = '', Fill in the characters in the middle of '', such as dfdf877ddff.

6, phpmyadmin appeared 1045 error The results of the search from the Internet are said that because of the password problem, I did not encounter the password problem, but I use the domain name form on the server to access, such as http: //blog.tryboy.org/phpadmin, if you use http://localhost/phpmyadmin or http://127.0.0.1/phpmyadmin to access everything is normal, probably because MYSQL is set up “ remote host is not allowed to access through ROOT permissions” So, using http://blog.tryboy.org/phpadmin to access it is considered a remote host access.

7, phpmyadmin appears "can't load mcrypt extension, please check PHP configuration" prompts Although this prompt appears, it has no effect on general use. If you want to solve it, first in the php.ini configuration of PHP, remove the php_mcrypt.dll; remove it. 2. Copy libmcrypt.dll from php5 to the system32 directory.

8, want to enable Apache's Rewrite Mod, you need to modify the #LoadModule rewrite_module modules/mod_rewrite.so in the httpd.conf file, remove the ##.

9, modify the httpd.conf file to restart Apache to take effect.

Copyright © Windows knowledge All Rights Reserved