I think I'm stuck in a 301 redirect loop
-
Hi all, I'm trying to correct some of my duplicate content errors. The site is built on Miva Merchant and the storefront page, /SFNT.html, needs to be permanently redirected to www.mydomain.com
This is what my .htaccess file looks like:
#RedirectPermanent /index.html http://dev.mydomain.com/mm5/merchant.mvc?
RewriteEngine On
RewriteCond %{HTTP_HOST} !^dev.mydomain.com$ [NC]
RewriteRule ^(.*) http://dev.emydomain.com/$1 [L,R=301]
DirectoryIndex index.html index.htm index.php /mm5/merchant.mvc
redirect 301 /SFNT.html http://dev.mydomain.com/
RewriteCond %{QUERY_STRING} Screen=SFNT&Store_Code=MYSTORECODE [NC]
When I use this code and navigate to http://dev.mydomain.com/SFNT.html the URL gets rewritten as http://dev.mydomain.com/?Screen=SFNT
So I believe this is what's called a "redirect loop"....
Can anyone provide any insight? I'm not a developer, but have been tasked with cleaning up the problems on the website and can use any input anyone is willing to offer.
Thanks,
jr
-
Wow, I've been working with Miva's Design Club, going back and forth on how to fix this, for over a month. I should have asked the question here. I can finally get down to fixing this issue.
Thank you!
jr
-
In this case you need to use rel Canonical
His your reference from Miva Merchant
http://www.mivamerchant.com/blog/google-addresses-duplicate-content
-
I just tried adjusting as below and it still rewrites the URL to http://www.mydomain.com/?Screen=SFNT
RedirectMatch 301 /SFNT.html http://dev.mydomain.com
-
Redirect Loop is when you create 2 opposite redirect rules.
and basically your site will never load at al,l because the browser will time out
did you try ?
RedirectMatch 301 /STNT.html http://www.domain.com
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Should I set 301 Redirects or keep old permalinks?
I just built a new site for a client and the new site has pretty links like domain.com/about-us. The old site has been around for a VERY long time and had links like domain.com/aboutus. I want to do 301 redirects because from my understanding, it minimizes the negative SEO impact. But the client wants to keep the permalinks without the hyphens to match the old links. What is the best route, considering SEO? BTW, the site is still on the same domain. Thanks in advance for your help! Neik
Technical SEO | | glassh0use0 -
Migration to New Domain - 301 Redirect Questions
My client is migrating their site to a new domain. I just did a big redesign, including URL structure change, and 301s from old URLs to new URLs. Now they want a new name, so we're moving forward with a new domain name. However, we're going to keep the site on the current domain while we ease customers into the new name. During that time, I'm going to be building links to the new domain name and 301 Redirecting that new one to the current domain name. Then, once we migrate the site to the new domain name, I'm then going to redirect the current domain name to the new domain name. So, my question(s) is/are: Is the above process the best way to use 301 redirects to to build links to the new domain while we transition everything? Should I (or can I) do 3 redirects from the oldest URLs, to the current URLs then to the new URLs? General question... I can't seem to find this anywhere online, but what is the best practice for what order URLs should be in in the htaccess file? Thanks!
Technical SEO | | Kenny-King0 -
301 Redirects in subfolders
Hi, we're making our site into a static site but I would like to transfer the Google juice. Most of the links and database exist on subfolders though. Could I simply do 301 redirects on the subfolders and retain the value or does it have to be on the full domain?
Technical SEO | | Therealmattyd0 -
Fix redirect loop
Hi,
Technical SEO | | bshanahan
I've been trying set up a 301 redirect from http://domestiquecap.com to www.domestiquecap.com but one was already set up by my client the other way around (from www to http://) so it's creating a redirect loop. However, we don't know where that original redirect was set up. The htaccess file doesn't appear to have the redirect and neither does the control panel of our hosting company. We need to turn off that original redirect so that I can instead redirect to the www subdomain. Where else could this 301 redirect have been set up? Is there a tool to diagnose where the 301 redirect was created so that I can turn it off? I am thinking maybe it was created via the domain registrar (GoDaddy) since the client has the login there and hasnt shared it with me.0 -
301 redirect relative or absolute path?
Hello everyone, Recently we've changed the URL structure on our website, and of course we had to 301 redirect the old urls to the coresponding new ones. The way the technical guys did this is: "http://www.domain.com/old-url.html" 301 redirect to "/new-url.html"
Technical SEO | | Silviu
meaning as a relative redirect path, not an absolute one like this:
"http://www.domain.com/old-url.html" 301 redirect to "http://www.domain.com/new-url.html" This happened for few thousands urls, and the fact is the organic traffic dropped for those pages after this change. (no other changes were made on these pages and the new urls are as seo friendly as possible, A grade on On-Page Grader). The question is: does the relative redirect negatively affects seo, or it counts the same as an absolute path redirect? Thanks,
S.0 -
Diagnostics say I'm missing Page titles... but I am not?
I've been running a crawl of one of our new site builds for a couple of weeks. The Diagnostics picked up a couple of issues, which was great, but it's saying we're missing Page Titles and Descriptions on pages that we have Page Titles and Descriptions. Anyone come across this before?
Technical SEO | | niamhomahony0 -
When is it safe to remove 301 redirects?
I have created over 500 301 redirects in my .htaccess file, some of them are more than 2 years old now. Should I delete them? I don't like seeing the "notices" number in crawl diagnostics so high 😞
Technical SEO | | danielshaw0 -
Any issues with lots of pages issuing 301 redirects?
Hi all, I'm working on a site redesign and it is possible the new site could issue a lot of 301 redirects as we may migrate from one forum solution to another. Is there any issue with crawlers getting a lot of 301 redirects from a site? Thanks Nick
Technical SEO | | nickswan0