PHP can not parse the judgment fault
1./usr/local/apache/bin/apachectl-m//View there is no load php5_module (shared) module;
2. Under the/usr/local/apache2/modules/directory, see if the libphp5.so module is loaded;
3. Review the compiled configuration file. No error:/usr/local/apache2/conf/httpd.conf
Modify the Apache configuration file httpd.conf
vim/usr/local/apache2/conf/httpd.conf
found in httpd.conf: "AddType application/x-gzip. Gz. tgz" is added below the line
"AddType application/x-httpd-php. php"
Find further : "DirectoryIndex index.html", modify this line to
"DirectoryIndex index.html index.htm index.php"
Find again: "#ServerName www.example.com:80" changed this line to
"ServerName localhost:80" save back
4. Use the command to see if the Master profile is incorrect:/usr/local/apache2/bin/apachectl-t
5. When compiling and installing Apache, it is recommended to add two parameters (no need to compile later):
--enable-modes-shared=most//Compile the most loaded modules
--enalbe-modes-shared=all//compile and load all modules
In short, after the failure, the first to determine the cause of the problem, so that there is a way to deal with.
/usr/local/apache2/bin/apachectl-m: See which modules are installed
/usr/local/apache/bin/apachectl-v: Viewing the mode used
/usr/local/apache2/bin/apachectl-t: Checking for syntax errors
/usr/local/apache2/bin/apachectl-l: Viewing the installed library files
/usr/local/apache2/bin/apachectl Graceful: Reload configuration
/usr/local/apache2/htcocs Home Store Directory
/usr/local/apache2/bin/apachectl Startup file directory
Apache cannot parse the PHP file