Php + apache environment configuration errors

Source: Internet
Author: User
After installing PHP in Windows, Apache may encounter the LoadModuletakestwoarguments error. The main cause is httpd. this sentence in conf: LoadModulephp5_moduleD: ProgramFilesPHPphp5apache2_2.dll the interpreter treats the null value in ProgramFiles as the separator of the two parameters. Therefore, the statement

After installing PHP in Windows, Apache may encounter the LoadModule takes two arguments error. The main cause is httpd. in conf, The LoadModule php5_module D: \ Program Files \ PHP \ php5apache2_2.dll interpreter treats the null values in Program Files as the separator numbers of the two parameters. Therefore, the statement

After installing PHP in Windows, Apache may encounter the LoadModule takes two arguments error. The main reason is the following sentence in httpd. conf:
LoadModule php5_module D: \ Program Files \ PHP \ php5apache2_2.dll
The interpreter regards the space in Program Files as the separator of two parameters, so no space is allowed in the statement. I did not find a solution after searching for a long time on the Internet. I finally used the level-1 directory symbol to solve the problem. I changed it to the following:
LoadModule php5_module ../php/php5apache2_2.dll

Because apache is installed in the D: \ Program Files \ Apache \ directory, PHP is installed in D: \ Program Files \ php \, so .. /indicates the D: \ Program Files \ directory. This is the Final Solution. I hope you will always find a way to use your brains during installation and configuration.


I like development very much. I have my own website on Internet Learning: www.xueyizhi.com, corresponding Forum: bbs.xueyizhi.com, and technology QQ group: 175603095. welcome to join us!

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.