Configuration of apache.php and MySQL

Source: Internet
Author: User

1. First Apache PHP MySQL installation package
2. Create a new folder on the D-Disk for myphp2017
2. Parsing Apache installation package in myphp2017
3. Open Apache below the conf below the httpd.conf, for steps to modify
① change the path of ServerRoot to "D:\myphp2017\Apache"
② change the path of Dodocumentroot to "D:\myphp2017\Apache\htdocs"
③ the path to Dodocumentroot directory below is also changed to "D:\myphp2017\Apache\htdocs"
④ change Scriptalias to scriptalias/cgi-bin/"D:\myphp2017\Apache\cgi-bin"
⑤ change to "D:\myphp2017\Apache\cgi-bin" in Directory
After changing to
<directory "D:\myphp2017\Apache\cgi-bin" >
AllowOverride None
Options None
Require all granted
</Directory>


Apache is ready to deploy.


4. Parse the PHP installation package into myphp2017

5. Under Apache conf below the httpd.conf, proceed with the steps to modify
① on the last side of httpd.conf plus PHP configuration
Phpinidir "D:\myphp2017\php-7.0.23"
LoadModule php7_module "D:\myphp2017\php-7.0.23\php7apache2_4.dll"
AddType application/x-httpd-php. php
② a copy of the php.ini-development or php.ini-production under D:\myphp2017\php-7.0.23
Its name is php.ini
③php.ini extension_dir Modify path to Extension_dir = "D:\myphp2017\php-7.0.23\ext"
Information configuration in php.ini
ENABLE_DL = On
Cgi.force_redirect = 0
Cgi.fix_pathinfo=1
Fastcgi.impersonate = 1
Cgi.rfc2616_headers = 1
PHP configuration is ready.

6. Install Mysql-5.5.57-winx64.mis, to myphp2017


7. Configure the Apache virtual directory

① found the hosts under C:\WINDOWS\SYSTEM32\DRIVERS\ETC.
② in the hosts and 127.0.0.1 www.blog.com (local name address)
③ in httpd.conf under Conf under Apache.
At the bottom of the virtual hosts strip.
④ found the httpd-vhosts.conf under D:\myphp2017\Apache\conf\extra.
⑤ all the notes in it, add
<virtualhost *:80>
#邮箱名
ServerAdmin[email protected]

DocumentRoot "D:\myphp2017\blog\php"
ServerName www.blog.com
DirectoryIndex login.php
Errorlog "Logs/blog.com-error.log"
Customlog "Logs/blog.com-access.log" common
<directory "D:\myphp2017\blog\php" >
Options Indexes FollowSymLinks
AllowOverride None
Require all granted
</Directory>
</VirtualHost>


Configuration of apache.php and MySQL

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.