Welcome to WebmasterWorld Guest from 220.127.116.11
I've recently discovered a very handy method of forcing your server to treat .php files as if they were .html by adding the following line to an .htaccess file:
AddType application/x-httpd-php .php .html
The result is that you can create .html files with embeded PHP scripts and they are parsed in exactly the same way.
What I want to know is will a spidering engine such as Google or Inktomi be able to differenciate between a normal .html page and one that has been through the PHP interpreter. Both appear as plain HTML in the browser, but will this affect spidering?
FYI - none of these pages will have variable=value pairs passed in the URLs such as index.html?prod=23.
The thing I can think of is that the LastModified Header won't be sent(by default) with your processed pages. That's a decent way to tell if the page was preprocessed or static.
See Are you using If Modified Since? [webmasterworld.com] for some useful info.
I was just wondering if some spiders might take 2 identical pages, one with .php and one with .html and give the latter a better ranking.
My other concern was that the spider may somehow detect that it was being served a dynamic page even though it had a .html extension and somehow penalise for it.
The 304 page header info was good, thanks slade.
Most search engines read PHP perfectly fine, since they get the HTML just as a web browser does (ie. View Source is what the search engine spiders see).
But I hear what you're saying. Processing true HTML files when they don't contain any PHP is not only pointless but draining on server resources.
Should probably be used with care.