1. Configure apache to call the "php language module (engine)" to execute the php code. Apache's main configuration file httpd.conf is required. Its location is: apache installation directory/conf/httpd.conf
#2. Find the location of "Loading Module": and in At the last position of this series of LoadModules, add this line: "LoadModule actions_module modules/mod_actions.so", the module file in the php5 language package. Among them, the php5 language module name is a fixed name, which is: php5_module, php5 language package, In fact, it is the folder of the php language package
3. At the end of the apache configuration file, write: LoadModul php5_module "H:/amp/php/php5apache2_2.dll"
4. Start a new line to set the file with php suffix, which will be executed by this php language module. "AddType application/x-httpd-php .php"
5. Restart Apache
Recommended tutorial: PHP video tutorial
The above is the detailed content of How to configure php in apache. For more information, please follow other related articles on the PHP Chinese website!