Forum Moderators: open

Message Too Old, No Replies

PHP and Google

         

fuzzatonic

3:14 pm on Apr 24, 2003 (gmt 0)

10+ Year Member



As part of the process of making the decision to go to an all-PHP site, I am investigating the implications of leaving the file extensions as .html, but actually using the PHP rendering engine for these pages.

My biggest concern with this approach is the possible negative reaction from Google. Will Google consider this approach as less-than-honest and ban us from inclusion?

dmorison

3:29 pm on Apr 24, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hi fuzzatonic,

The search engine robots really don't care how your page was created as long it returns well structured HTML.

Besides, if you return some HTML in response to a request for a .html file it is impossible to know if that page was generated on the fly or not.

However,

When people talk about the problems of dynamic pages and search engines; it is not so much about how the page was created, but how search engine spiders deal with complex URL's that contain all sorts of variables being passed back and forth between client and server.

For example, where you have a URL looking like:

somepage.html?foo=bar&color=red&size=large etc. etc. etc., then a spider may think twice about following it.

Search this site for "dynamic pages" for plenty of threads on this subject.

Cheers.

brotherhood of LAN

3:49 pm on Apr 24, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



>> but how search engine spiders deal with complex URL's

Agreed. It's also nice for security I believe, I have a dictionary.asp page that uses PHP, anyone would think it was ASP :)

There is an option called "expose PHP" in the php.ini file. If you turn it to "off" and have static URL's I can't see any way that a bot could know you are using a scripting language like PHP/ASP

BGumble

3:58 pm on Apr 24, 2003 (gmt 0)

10+ Year Member



Good suggestions so far, but also use mod_rewrite for friendly URLs:

[yourdomain.com...]

instead of

[yourdomain.com...]

The second link is no better than using the php extension. If you don't want to use mod_rewrite you can also parse out the REQUEST_URI to get the variables

if (!ereg("=",getenv('REQUEST_URI')) and (!ereg("\?",getenv('REQUEST_URI')))) {

$url_array=explode("/",getenv('REQUEST_URI')); //BREAK UP THE URL PATH

etc etc