Forum Moderators: open
Will changing index.htm to index.php have any effect on my rankings?
I am placed very well at the moment (1st page on most keywords) and I don't want to loose that!
I need to add a php function to index page, other than that the page will remain the same.
dhdweb
You can let useragents know that an old resource is now available under a different URL by sending a 301 Moved Permanently status code and the new URL in the Location header. This is the methods suggested by Google. This should not hurt your ranking.
But if you think about it, changing the URL of a resource just because the underlying technology used to produce that resource changed is a bad idea. If you change to Perl as your scripting language in the future, do you want to change your extension to .pl?
Think about using some internal rewriting technique or configure your webserver to treat files with the extension of .html as php code.
Andreas
If you put
DirectoryIndex index.phpin your .htaccess file and take care to refer to that page only without the file name and you did so in the past as well then all will work well using this method.
Andreas
So if all your external links refer to the domain name and the link in google refers to the domain name then there should be no problem as far as ranking is concerned.
Andreas
Now the question probably still lies - Will an equally ranked site do better if .html or .php... This I can not answer for sure, but some of our Client sites do well with .php index and other pages..
Hope it helps... :)
As someone else above said, you shouldn't have to change your filename just because you changed the underlying scripting language.
You can use any_file_name.php and have it appear to the user as index.html, and without messing up any previous linking or rankings. (I have some code I can post, if you don't find what you're looking for.)
I am going to play it safe here and wait until I get an answer directly from Google, I just hope they don't take forever to answer my e-mail to them.:)
Personaly, I don't see why changing the file extention would make a difference since no outside links refer to the index file, they only point to my domain name. That plus the fact that the page will still be writen in html and I am not changing the current content but just adding some php functionality.
Anyway, when I hear from Google, I will let you thier answer on this.
dhdweb
I then placed a link to the forums in my navigation bar which is on every page in my site. The link was to /forums/ (rather than /forums/index.php).
After two Google updates, I can see a definite difference in PR between http://www.mydomain.com/forums/ (PR5) and http://www.mydomain.com/forums/index.php (PR3)
Google therefore hasn't successfully determined that the two URLs in fact point to the same page. In contrast, Google has successfully determined this for http://www.mydomain.com/ and http://www.mydomain.com/index.html
If you set up a 302 redirect on the specific request of one or the other, Google could that they are the same.
After pondering it some, though... I don't know how much this would affect the page's PR. My original theory was you would improve the page's PR by merging the pages inbound links. I have not convinced myself of this, yet.
product_info_1.htm
product_info_2.htm
No questions about whether pages are considered to be the same, whether they will be indexed, whether the query string is too long, whether Google will do this if something happens in China.
Simple static URIs that every spider will follow and which may even be remembered by your users.
There is a reason why Brett uses URIs like [webmasterworld.com...] instead of [webmasterworld.com ]. There is no reason why you shouldn´t do it too.
Andreas
People in this forum are suggesting that we can run php scripts in the disguise of html but if only one instance of a dynamic page is indexed, then I cannot see much benefit!
Can anybody confirm whether SE spiders will treat index.htm?id=1 as a different page to index.htm?id=2 (?)
(Thanks for your comments, though, Andreas!)
Can anybody confirm whether SE spiders will treat index.htm?id=1 as a different page to index.htm?id=2 (?)
I just checked and had multiple listings for an asp page.
/custom.asp?itemnum=ct001
/custom.asp?itemnum=ct002
/custom.asp?itemnum=ct003
/custom.asp?itemnum=ct004
/custom.asp?itemnum=ct005
...and so on
I think I've maybe not made my question clear!
SEs will index a php/asp page as seperate pages if they have different parameters (eg.?id=1,?id=2) because they are known to be a dynamic page. The SE therefore expects that they may be different and will treat them as different pages, although they essentially are the same document.
My question relates to running php documents with an html/htm extension. As an html page is a "Static" page, will the search engine only index it once, even though there are many links to the page with different parameters?
My listing in google is [domainname.com...] (not real domain). So I changed my index page from index.htm to index.php
And you know what? Nothing bad happened. Did not lose any page rank, traffic, search positions. If anything else, this month I have the most traffic I have ever had. This is probably due to the extra features that PHP allows me to incorporate into my site.
So...be a leader not a follower like other webmasters. Experiment and have fun.
I do try to have fun, but money is unfortunately more of an incentive.
It WILL make no difference as the default page, as this is being served up with only the domainname in the URL - the SE doesn't see this.
It is where the .php is specifically used in the URL (e.g. http:/domainname.com/product.php), that causes the SE to spider less of the site (generally speaking I believe that 1 level of spidering happens in php compared to the entire site being indexed using .html pages).
Please feel free to correct me if I am wrong, you guys!