Click to See Complete Forum and Search --> : Redirects


chestertb
11-09-2006, 07:17 AM
Hi All,

Does a search engine follow a redirect?

I'm experimenting a little with subdomains and redirects, and I need to know whether a search engine will follow a redirect when it starts to index a site.

For example, index.htm in the subdomain test.mydomain.com will have something like this...
<head>
<meta httpequiv='REFRESH' content='0; URL=http://www.mydomain.com/index.php?id=112'>
</head>
The id will tell php which mysql database it should load for that subdomain. Each subsequent page call will also have the id=112.

For it all to work, the search engine would have to follow the redirect. Will it?

grumpyoldtechs
11-11-2006, 05:38 PM
wouldn't it be easier to use header("Location: url.com");

from what i've read a search engine doesn't like a page which refreshes under 500 seconds or something.

i think it would look for certain code and also follow the links bots are constantly being updated and becoming more advance

chestertb
11-11-2006, 05:46 PM
Doesn't header("Location:url.com") simply send a header set that looks something like this...?
<head>
<meta httpequiv='REFRESH' content='0; URL=http://www.mydomain.com/index.php?id=112'>
</head>

That would mean the bot would have to follow it any way.
Or have I misread the nature of the php "header" function?

CTB

aidanmack
12-05-2006, 10:22 AM
I have a very similar problem.
Our old site uses standard html.
but now our site is database orientated.

when u do a search in google for our site our html pages always come up tops.

what i would really like to do is re-direct from that html to our new spanking php pages.

However am i correct in thinking that if a bot picks up a redirect in the html page it will delete the page from its site database so it wont come up in a search engine anymore??


soooo my other idea was to replace the relevant html in our html page with a i-frame and loaded in our new php files. But then the bots woulnt see the info thats being loaded in to the iframes. so thats a no no.

Soo really what im trying to say is, how do you redirect to another site while keeping the site your redirecting from to the top of a search engine?

what do other people do.

cheers
Aidan

manpasand
12-06-2006, 09:05 PM
Why don't you use 301 redirect with using .htaccess.

chestertb
12-07-2006, 01:32 AM
The other option is to use a javascript redirect. That way, the bot will still see your shiny html pages that it's worked so hard to index, so it will retain the ranking for that page.

Something like...
<head>
<script language='javascript'>
function redirect()
{
top.location='http://www.yoursite.whatever';
}
</script>
<body onload='javascript:redirect()'>
etc...

The downside of this is that the entire page will load before it redirects, which means your visitor has to wait.

If you use the iframe route, just have a link on the top page to the content of the iframe. As long as a bot has a link to follow, it will follow it and index that the page. Even if the link is hidden, the bot will follow it without penalty.

You then place the old content within a hidden div. The bot will still index it and retain its ranking because it ignores the dhtml that shows or hides div content. Just remember to replace all your pics with a tiny single pixel image so that your user doesn't have to wait for those pics to load.

innominds
12-07-2006, 08:24 AM
I'm also facing the same problem. Earlier i've used a free hosting service(50webs). Right now i've moved to a paid one. How can i redirect the traffic from the old site to the new one. Could anyone explain me?

Dranoweb
08-17-2007, 01:56 AM
why are all the topics I find - a year or more old?

Anyway that aside:

As a slight deviation from the topic I have a slight issue with what seemigly should be a basic and straightforward operation.

I have a site (dranoweb com) and have an iframe dead center to load the content.

I'm trying in vain to make the content pages redirect to the main page, (got this bit working ok) and then have the iframe load the page originally intended within the iframe.

I have found a host of codes to do this, but as I have no frameset to speak of, most of the javascripts I have found to do the job, don't work.

Not being very profoicent in javascript - can someone point me in the direction of a thread that may assist?