The server architecture is: linux + apache + mysql + php Folder: css,img,templates(included file index.html) file: index. php where the index. php code is as follows :? Phpinclude(.templatesindex.html );? The templatesindex.html code is as follows :! DOCTYPEhtmlPUBLIC-W3CDT
The server architecture is: linux + apache + mysql + php Folder: css, img, templates(included file index.html) file: index. php where the index. php code is as follows :? Php include ('./templates/index.html ');? The templates/index.html code is as follows :! DOCTYPE html PUBLIC "-// W3C // DT
The server architecture is: linux + apache + mysql + php
Folder: css, img, templates(include file index.html)
File: index. php
The index. php code is as follows:
<? Php include ('./templates/index.html');?>
The templates/index.html code is as follows:
<! DOCTYPE html PUBLIC "-// W3C // dtd xhtml 1.0 Strict // EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <ptml xmlns = "http://www.w3.org/1999/xhtml"> <pead> <title> untitled document </title> <meta http-equiv = "Content-Type" content = "text/html; charset = UTF-8 "/> </pead> <body> this is test... </body> </ptml>
It can be displayed normally in non-IE environments,
However, if you access index. php in IE, it cannot be displayed (blank), but right-click to view the source code is correct.
This error is inexplicable. I finally solved it like this:
Copy the correctly displayed page, replace templates/index.html, replace the content in the body with the content you want to display, and then you can display the page correctly without saying anything...