Install apache2.2.22 Configure php5.4 of

  • 2020-06-22 23:59:45
  • OfStack

Modify the apache2.2/ httpd.conf configuration file so that apache can parse php files

# Modify the listener port
Listen 8011

Add the following sentence after the last paragraph of LoadModule
LoadModule php5_module "E:/LAMP/php5.4/php5apache2_2.dll"

Modify the server web directory as E:/LAMP/www
DocumentRoot "E:/LAMP/www"
There's one more thing to change
< Directory "E:/LAMP/www" >

# in < IfModule dir_module > Add index. php to index. html, that is, open index. php by default, and open index. html if no
< IfModule dir_module >
DirectoryIndex index.php index.html
< /IfModule >

Add the following two sentences after AddType application/ x.gz.tgz
AddType application/x-httpd-php .php .phtml
PHPIniDir "E:/LAMP/php5.4"

Modify es64EN5.4 / ES65en. ini-ES67en profile
First, rename the php.ini-ES71en file to ES72en.ini

; Set the extension library path of php, find; extension_dir = "ext", add the following sentence below
extension_dir = "E:/LAMP/php5.4/ext"

; Open the php extension library
;extension=php_gd2.dll
;extension=php_mbstring.dll
;extension=php_mysql.dll
;extension=php_mysqli.dll
; Remove the semicolon from the four sentences above

; Set session temporary save path, find; session.save_path = "/tmp", add the following sentence (the path is free to set)
session.save_path = "E:/LAMP/php5.4/session_temp"

; Similarly, cookie temporarily saves the path
session.cookie_path = "E:/LAMP/php5.4/session_temp"

After configuration, then E: LAMPphp5. 4 ext directory
php_mysql. dll and php_mysqli. dll
Copy and paste the two files into the "C:WindowsSystem32" directory,
If your operating system is win7x64, copy and paste it into the "C:WindowsSysWOW64" directory.

ok, now reboot your apache and see if it works.
Test run phpmyadmin under 1 to see if it works. If it works, we're done.

Note: No installation method for mysql is provided here. If you didn't install mysql before, go to another baidu.


Related articles: