Welcome to WebmasterWorld Guest from 54.196.175.173

Forum Moderators: open

Message Too Old, No Replies

Is a double redirect bet for google?

     

killroy

8:57 am on Apr 9, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I'm currently wondering if settign up a double redirect is the best way to maintain google listings and neat addresses while avoiding duplicate content and 404s.

Basically to move from man ugly:
/somefolder/cgi-bin/somescript.cgi/somecategory/someid
to
/somecategory/someid

I frest set a mod_rewrite fform the later to the first.
This works, well and should add the nice from to teh google index with the next crawl. But google might re-spider the old address as well causign me to show duplicate content.

So I wonder how to set up a double redirect like this:
FROM
/somefolder/cgi-bin/somescript.cgi/somecategory/someid
TO
301 permanent redirect /somecategory/someid

AND
FROM
/somecategory/someid
TO
internal redirect somefolder/cgi-bin/somescript.cgi/somecategory/someid

in mod_rewrite without infinite loops.
And woudl that have the desired effect of google expelling hte original old URLs from its index and replacign it with the new form while still makign external links fanctional?

SN

Spannerworks

11:12 am on Apr 9, 2003 (gmt 0)

10+ Year Member



How about putting a script in each of your pages that checks for external referrals to the page containing the string "cgi-bin"? If so, 301 redirect to the nice URL, if not, serve the page as usual.

frogg

1:22 pm on Apr 9, 2003 (gmt 0)

10+ Year Member



I believe either of these solutions would work just fine!

hth,
fRoGG

killroy

3:11 pm on Apr 9, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



The problem is the nice URL redirects back to the proper one. how do I prevent infinite recursion in the mod_rewrite?
I once downed the server for a few hours accidentally with a bad rule.

SN

 

Featured Threads

Hot Threads This Week

Hot Threads This Month