3 Replies - 939 Views - Last Post: 13 February 2013 - 12:10 PM

#1 SevenKader  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 32
  • Joined: 29-January 13

How to redirect from blogger home page only, to another website

Posted 11 February 2013 - 03:25 PM

I want my homepage to be sent straight to another website, and not any other page. Anyone know how to do this?
Is This A Good Question/Topic? 0
  • +

Replies To: How to redirect from blogger home page only, to another website

#2 Atli  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 3719
  • View blog
  • Posts: 5,991
  • Joined: 08-June 10

Re: How to redirect from blogger home page only, to another website

Posted 11 February 2013 - 03:33 PM

Ideally you'd alter the DNS record so that the domain name itself points to the new website. However, I'm guessing that's not in the picture here.

You can redirect in HTML using a meta refresh tag.
<meta http-equiv="refresh" content="0;http://example.com/">



You can also use Javascript to do the same, though it's not as reliable.
<script>
location.href = "http://example.com/";
</script>



Both of these methods suffer from an inefficiency problem, though, as they have to wait for the original page to be loaded before the redirect. A more efficient way to do this would be to use a HTTP Location header, which would be sent by the server-side code. For instance, in PHP, you might do this:
<?php
header("Location: http://example.com/");
exit;


And now no content would have to be sent or received by the browser, and you'd be redirected immediately.
Was This Post Helpful? 0
  • +
  • -

#3 LawlessBaron  Icon User is offline

  • D.I.C Head

Reputation: 5
  • View blog
  • Posts: 115
  • Joined: 07-February 13

Re: How to redirect from blogger home page only, to another website

Posted 12 February 2013 - 06:53 PM

You could try a simple redirect in the .htaccess
Was This Post Helpful? 0
  • +
  • -

#4 Atli  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 3719
  • View blog
  • Posts: 5,991
  • Joined: 08-June 10

Re: How to redirect from blogger home page only, to another website

Posted 13 February 2013 - 12:10 PM

Yea, that would be better than the meta tag or the Javascript redirect. It's probably blocked by the host though, if not for security then because it doesn't really make sense for a blogging platform to allow users to redirect away from them like that.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1