Install apache2.2.22 and configure php5.4 (Procedure)

Source: Internet
Author: User

Modify the configuration file apache2.2/httpd. conf so that apache can parse the PHP File

# Modifying the listening port
Listen 8011.

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

# Modify the server website directory to E:/LAMP/www
DocumentRoot "E:/LAMP/www"
# There is another place to change
<Directory "E:/LAMP/www">

# In Front Of index.html in <IfModule dir_module>, access index.php first. If no index.html is available, access index.html again.
<IfModule dir_module>
DirectoryIndex index. php index.html
</IfModule>

# Add the following two sentences after AddType application/x-gzip. gz. tgz to add an executable file:
AddType application/x-httpd-php. php. phtml
PHPIniDir "E:/LAMP/php5.4"

Modify the php5.4/php. ini-production configuration file
First, rename the php. ini-production file to php. ini.

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

; Enable php extension Library
; Extension = php_gd2.dll
; Extension = php_mbstring.dll
; Extension = php_mysql.dll
; Extension = php_mysqli.dll
Remove the semicolon in front of the above four sentences

; Set the temporary session save path and locate; session. save_path = "/tmp", add the following sentence below (the path can be set freely)
Session. save_path = "E:/LAMP/php5.4/session_temp"

; Similarly, the temporary cookie storage path
Session. cookie_path = "E:/LAMP/php5.4/session_temp"

After the configuration
Php_mysql.dll and php_mysqli.dll
Copy and paste the two files to the "C: WindowsSystem32" directory,
If your operating system is win7x64, copy and paste it to the "C: WindowsSysWOW64" directory.

OK. Restart your apache to see if it works.
Test and run phpmyadmin to see if it can be run. If it works properly, it will be done.

Note: The Installation Method of mysql is not provided here. If you haven't installed mysql before, go to Baidu.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.