Home  >  Article  >  Backend Development  >  What should I do if html cannot output php code?

What should I do if html cannot output php code?

藏色散人
藏色散人Original
2022-01-28 09:23:162304browse

The solution to the problem that html cannot output php code: 1. Open httpd.conf; 2. Add "AddHandler php5-script .php .html AddType text/html .php .html"; 3. Restart the service. .

What should I do if html cannot output php code?

The operating environment of this article: Windows7 system, PHP5 version, DELL G3 computer

html What should I do if the php code cannot be output?

html embedded php code cannot be parsed

php and apache are installed, but the browser cannot parse the php code for such code.

d

Problem solution:

Add the following two items to httpd.conf and restart.OK!

AddHandler php5-script .php .html
AddType text/html .php .html

Recommended study: "PHP Video Tutorial"

The above is the detailed content of What should I do if html cannot output php code?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn