PHP-based development environment under PHP Win7
Today re-made a win7 system, all the environment reconfiguration
?
The steps are as follows:
?
One, download Apache, version: Httpd-2.2.17-win32-x86-openssl,apache installation Nothing special, the default can be
?
Second, install MySQL, version: 5.1, similarly, the default installation can be
?
Third, install PHP, version: php-5.3.5-win32-vc6-x86, note: VC9 is specifically for IIS customization, VC6 is for other Web services software provided, such as Apache, I downloaded the zip package.
?
And here's the configuration
?
1. Find
On Windows:; Extension_dir = "ext"
Change to:
; On windows:extension_dir = "D:/php/ext"
?
2. Add some common library extensions, such as MySQL, to remove the previous points
Extension=php_curl.dllextension=php_gd2.dllextension=php_mbstring.dllextension=php_mysql.dllextension=php_pdo_ Mysql.dllextension=php_pdo_odbc.dllextension=php_xmlrpc.dll
?
? 3. Configure the session function of PHP
Session.save_path = "D:/phpsessiontmp"
?
4. Configure the PHP file upload function
Upload_tmp_dir = "D:/phpfileuploadtmp
?
5. Modify the Date.timezone, otherwise the date portion is the U.S. LA Time by default when executing phpinfo
Date.timezone = Asia/shanghai
?
6. Enable Apache to load conf/extra/httpd-vhosts.conf to set up a virtual host
# Virtual Hostsinclude conf/extra/httpd-vhosts.conf
?
7. Configure the virtual host conf/extra/httpd-vhosts.conf
DocumentRoot "D:/phpserver/workspace" ServerName gm.me errorlog "Logs/dummy-host2.break.local-error.log" customlog "Logs/dummy-host2.break.local-access.log" Common
allowoverride None Options Indexes Order allow,deny
allow from all
?
8. We should know that the default Apache server executes the Web main program directory as Apache2.2/htdocs, so when your Web main program directory changes, we need to modify the corresponding Apache configuration
DocumentRoot "D:/phpserver/workspace"
?
9. Configure Apache to support PHP
LoadModule php5_module "D:/php/php5apache2_2.dll" Phpinidir "d:/php" AddType application/x-httpd-php. php. html. htm
Note here: If the PHP version of the download is incorrect, for example, without thread safety, you will find that the PHP directory is not
Php5apache2_2.dll
?
10. The specific index file order, due to the configuration of PHP features, of course, need to index.php priority execution
DirectoryIndex index.php index.html
?
?
?