Forum Moderators: open

Message Too Old, No Replies

What is the best way to include php code for better Google ranking?

There are 3 variants. Which is better?

         

GreenLeaf

2:50 pm on Nov 10, 2003 (gmt 0)

10+ Year Member



Hi all!
I need to include on my pages the result of sql query, so the question is: which variant will be better from Google ranking's point of view and from loading speed point of view:
1) to make pure php pages

2) to modify .htaccess for parsing html as shtml and make html page with <!--#include virtual="/test.php"-->

3) to modify .htaccess for parsing html as php and make html pages with php code

Thanks in advance.

linear

5:09 pm on Nov 10, 2003 (gmt 0)

10+ Year Member



Given that they all produce the same output if you do it right, I'd suggest benchmarking it on your own environment to find out which way is least resource-intensive.

PHP has some nifty microsecond-resolution timer calls that are handy for that purpose.

sabai

11:01 pm on Nov 10, 2003 (gmt 0)

10+ Year Member



Just do number 1 - Google doesn't care whether the extension is php or html and at a later date you might want to use plain .html pages somewhere else. I hate working on sites with lots of server side includes hidden away in the code. I think the tidiest option would be number 1... number 3 isn't bad, though it isn't needed.

GreenLeaf

9:55 pm on Nov 12, 2003 (gmt 0)

10+ Year Member



Thank you very much for your advices!

Imaster

10:43 pm on Nov 12, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



For the same purpose, I use option #2, but that's my preference :)

GreenLeaf

11:07 pm on Nov 12, 2003 (gmt 0)

10+ Year Member



Actually, i also use #2 on my first site. But now i'm working on the second one and i'm still not sure how to do it better.
I heard somewhere that php pages are ranked worse than pure html...
And does anybody know: do SSI calls make the page loading slowly?

Philosopher

11:13 pm on Nov 12, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Anything other than plain HTML such as SSI etc. will make the page load slower. However the affect is generally so small it doesn't really matter. It's when you have a large site with lots of SSI going on that you start affecting the server response and therefore page load-time (this can also happen on a shared server with lots of others eating up server resources).

Philosopher

GreenLeaf

4:28 pm on Nov 13, 2003 (gmt 0)

10+ Year Member



Thanks.
I have a lot (7-8 on a page) of SSI calls ...