Forum Moderators: open

Message Too Old, No Replies

Passing PR from index.html to index.php...

Passing PR from index.html to index.php...

         

ncreegan

4:34 pm on Apr 8, 2004 (gmt 0)

10+ Year Member



I'm changing over from an html index to a php index. What's the best way to pass the PR from the html index? Will google automatically assign the page rank to index.php if I just remove index.html?

Any input or direction on this is appreciated, thanks in advance!

WebGuerrilla

5:39 pm on Apr 8, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hi ncreegan,

Welcome to WebmasterWorld

The best thing to do would be to set your server up so that it will parse .html files for php.

Adding a line in your .htaccess file that looks like:

AddType application/x-httpd-php .php .php3 .html .htm

Should do the trick.

Doing that will allow you to keep all your file extensions as they are now. If that's not an option for some reason, you will want to make sure you setup 301 redirects for all the old extensions so that you will get credit for existing links.

skipfactor

5:51 pm on Apr 8, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



>>Will google automatically assign the page rank to index.php if I just remove index.html?

Yes--if your links are pointing to the root of your domain like they should be. Definitely do a 301.

ncreegan

6:06 pm on Apr 8, 2004 (gmt 0)

10+ Year Member



Thanks for the welcome and the advice!

slade7

6:39 pm on Apr 8, 2004 (gmt 0)

10+ Year Member



a while back I had the problem that some of my inbound links were pointing at www.mysite.com - and some were mysite.com, while all my internals were mysite.com.

On top of that, I had some inbound links to pages I had replaced (from html pages to php), so I went in and did some 301 redirects as needed (about 7 or 8 of them).

As for my home page, I had long since switched from index.html to index.php, but all my internal links pointed at /index.php - and inbound links pointed at "/" - so there I changed a great many of my inbound links to "/" too.

Have not ever done any url rewriting - still have query string in the url in lots of cases. But, I did go and make sure that every page that used a query string ALSO was valid without the query string AND linked to it that way from several places.

Result? All PR0 pages (about 20,000 of these) picked up to at least PR2 (these being the ones with query strings in the url mostly...), Homepage went from PR5 to PR6, and most important pages all improved PR. Serps improved accordingly.

After all improvement on my end, it took about 3-4 months to see PR improvement from Google. Serps improved after about 2 months I guess. 301 redirects will work!

<add>
I might add that I learned most of this nosing around here - otherwise I would be blissfully unaware - thanks WW!
</add>

ncreegan

12:01 pm on Apr 9, 2004 (gmt 0)

10+ Year Member



If I use the .htaccess to set html to be processed like php, will my dynamic html files be seen as dynamic, or will that data just be ignored?

If data.html?id=1 has information on widgets that are blue and data.html?id=2 has information on gadgets that are green, will a search engine index both of those pages and see them as unique, as long as I link to both of them elsewhere on the site?