how do i stop to my blog redirect to a country-specific URL?

Author Topic: how do i stop to my blog redirect to a country-specific URL?  (Read 6401 times)

Offline oliviasrodriguezTopic starter

  • Trade Count: (0)
  • Jr. Member
  • **
  • Thank You 6
  • Posts: 62
  • Karma: 2
  • Gender: Female
Many friends told me that you should stop your blog redirect to a country-specific url on your blog. What should i do now?


Offline Shikha Singh

  • Trade Count: (0)
  • Sr. Member
  • ****
  • Thank You 53
  • Posts: 307
  • Karma: 0
  • Gender: Female
  • solution to start online business
    • solution to start online business
Go to your blog inside the Blogger Dashboard and choose Template. Then click the “Edit HTML” button followed by “Proceed.” Next, copy-paste the following code into the template after the <head> tag.

<script type="text/javascript">
 
  // Written by Amit Agarwal
 
  /* Get the full URL of the current blogger page */
  var blog = document.location.href.toLowerCase();
 
  /* Do not redirect if the domain is .com already */
  if (!blog.match(/\.blogspot\.com/)) {
 
    /* Replace the country TLD with .com and ncr switch */
    blog = blog.replace(/\.blogspot\..*?\//, ".blogspot.com/ncr/");
 
    /* Redirect to the new .com URL in the current tab */
    window.location.replace(blog);
  }
 
  // Source: http://labnol.org/?p=21031
 
</script>

Offline kareem

  • Trade Count: (0)
  • Full Member
  • ***
  • Thank You 3
  • Posts: 122
  • Karma: 0
Stop Blogger from Redirecting to Country-Specific Domains
All you have to do is add an ncr/ to the end of the URL - ncr here stands for No Country Redirect.

Offline saravanan28

  • Trade Count: (0)
  • Sr. Member
  • ****
  • Thank You 2
  • Posts: 428
  • Karma: 0
Use Custom Domains: The users who are using custom domain will not be affected, since their url structure will remain the same and it will not be redirected ( Refer this). Adding 'ncr' slug to blog url: Adding a 'ncr' slug to your blog url stops the redirection and it shows the actual domain address.

Offline Lishmalinyjames

  • Trade Count: (0)
  • Hero Member
  • *****
  • Thank You 1
  • Posts: 651
  • Karma: 0
    • Oneplus Service Center in Chennai
One of the easiest ways to block Blogger's redirects is to manually add “/ncr” on to the end of the URL you are working with, in order to stay locked on to the original domain.


 

Related Topics

  Subject / Started by Replies Last post
1 Replies
2928 Views
Last post 05-09-2010, 22:35:46
by Nicpoint45
3 Replies
2483 Views
Last post 10-04-2011, 00:43:45
by Hogward
0 Replies
2292 Views
Last post 09-05-2014, 06:41:21
by centralseo
0 Replies
1604 Views
Last post 03-05-2016, 22:11:38
by mindblowing
0 Replies
1414 Views
Last post 04-23-2016, 04:58:00
by psyafter