Install apache2.4+php5.4+mysql5.7,apache2.4php5.4_php Tutorial under Windows

Source: Internet
Author: User

Install apache2.4+php5.4+mysql5.7,apache2.4php5.4 under Windows


Note: The installation process is written in the Win7 x86 under the test, the Baidu cloud download links provided are 32-bit installation packages, such as Apache and PHP 64-bit installation package please download from the official website!

First, install the Apache2.4.12

Apache Official Download Address:http://www.apachelounge.com/download/VC11/

32-bit installation package download link (Baidu Cloud):Http://pan.baidu.com/s/1bnuH04J

1. Download the file back as a compressed package, unzip it directly and put it in the location you want to install. (Take C:\Web\Acpache24 as an example)

2. Open apache24\conf under Httpd.conf file with Notepad

(1) The 38th line Define srvroot "/apache24" changed to Define srvroot "C:/web/apache24", that is, our Apache program to store the location after decompression. (Note that there is a difference between the forward slash and the path delimiter under Windows)

39th line ServerRoot "${srvroot}" change to ServerRoot "C:/web/apache24"

(2) No. 220 line #servername localhost:80 the "#" in front of the number removed

(3) The No. 244 line DocumentRoot "${srvroot}/htdocs" to DocumentRoot "C:/www" ( Here you need to set up a name www folder under the C disk , that The path where the root of the Web site is located, or it can be set to a different path according to its own situation

    The No. 245 line is similarly changed < p=""> to

(4) Line No. 278 directoryindex index.html to DirectoryIndex index.html index.php index.htm, this is to support more default pages including PHP

3. Start Apache: Open cmd, enter the command as shown, if the httpd.conf is configured correctly, enter httpd and press RETURN after no prompt ( Note: Do not close this command window, otherwise the Apache service will be turned off )

http://jingyan.baidu.com/article/4f7d57129fa86e1a201927de.html Solution

Re-open a CMD window as an administrator, enter the command as shown, where the string after-n is the service name, you can define it as a different one, you will be prompted in CMD after the installation succeeds, and you can see a service called "Apache24" in the "service". You can then manage the Apache service here.

CMD to run in Administrator mode

  (4) After the installation, we can manage the Apache service through the ApacheMonitor.exe of the Apache24\bin folder, the taskbar will also show this software, can more easily manage Apache run

Http://pan.baidu.com/s/1o6zKHmi

1. Download the file back as a compressed package, unzip it directly and put it in the location you want to install. (Take C:\Web\PHP as an example)

2. Copy the php.ini-development and rename it to PHP.ini

3. Open apache24\conf under Httpd.conf, at the end of the file, add

# PHP5 Support
LoadModule php5_module "C:/web/php/php5apache2_4.dll"
AddHandler application/x-httpd-php. php
# Configure the path to php.initially
Phpinidir "c:/web/php"

To support PHP, where the contents of two strings are PHP's path, depending on the location of PHP decompression and adjust themselves

4. Restart the Apache server

5. Test: Delete the other files in the C:\www folder, create a new index.php, the content is as follows

Phpinfo ();

?>

After saving to open the browser to access http://localhost, the information that appears in PHP indicates that PHP has been successfully installed

The basic installation of PHP is now complete!

Third, installation Mysql5.7.2.0

MySQL official download address:http://dev.mysql.com/downloads/mysql/

File download link (Baidu Cloud):Http://pan.baidu.com/s/1dDk3YMH

1. Run the installation file directly after download to install

2. Modify php.ini to support MySQL

(1) Line No. 721 Extension_dir = "ext", remove the preceding semicolon ";" and change to Extension_dir = "C:\Web\PHP\ext"

(2) Section 871, 872 lines, remove the front ";"

Extension=php_mysql.dll

Extension=php_mysqli.dll

Note: There are many DLLs in lines No. 859 through No. 896, what do you want to use , remove the front ";" You can do it.

(3) Restart Apache

http://www.bkjia.com/PHPjc/1027449.html www.bkjia.com true http://www.bkjia.com/PHPjc/1027449.html techarticle Windows installation apache2.4+php5.4+mysql5.7,apache2.4php5.4 Note: The installation process is written in the Win7 x86 under the test, provided by the Baidu cloud download link are 32-bit installation package, if necessary ...

  • 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.