Need some help with a tricky 301
-
I can't find anything online that deals with this issue. I have a page getting indexed by Google at mydomain.com/widgets and I don't know why. No links to it anywhere. The page it is closest to is mydomain.com/reviews/widgets and so I tried to set up a 301 to point one to the other.
The problem is each individual widget review is at mydomain.com/widgets/reviews/products/widget-name and so when I redirect /widgets to mydomain.com/reviews/widgets it also redirects each individual product to mydomain.com/reviews/widgets/reviews/products/widget-name.
Is there some way to just redirect /widgets without having it affect each product review? I cannot change URL structure either, nature of the site. Any ideas?
-
Hi Daniel,
Whenever I hear "Nothing is redirecting when I add this to the .htaccess file" I have one thought:
Is the site using Joomla, Drupal or some other CMS that will overwrite .htaccess rules externally?
Sha
-
Just not happening. I'm just not going to worry about it, thanks for your help
-
Gotcha. Try adding the rewriteengine on line directly above those two rules. That has to be present to trigger the mod_rewrite module. Hopefully that will solve the issue.
-
Yeah I took the ReweriteEngine On line out and just added the RewriteRule line in underneat that one. Although it doesn't say anywhere RewriteEngine On in the .htaccess file already, so not sure how that works.
-
Well, that's no fun. If there is already a line to initiate the rewrite engine, that 2nd 'rewriteengine on' reference could be a problem. I assume you took that out?
-
It is not working for me. Nothing is redirecting when I add this to the .htaccess file. First I added it as you suggested at the bottom of everything. Nothing happened so I added right after another line of code that was already in there that started with RewriteRule. This is the line that was already there:
RewriteRule ^.*$ index.php [NC,L]
Any idea what could be going wrong? Thanks in advance!
-
Hi Daniel - Are you using htaccess to handle your redirects. I think you'll need to employ some Regular Expressions to handle what you're trying to accomplish. As a guide, here is a very nice writeup on RegEx from - where else - SEOmoz: http://www.seomoz.org/blog/an-seos-guide-to-regex
so, in this case, i think what you'll want is:
RewriteEngine On
**RewriteRule ^widgets/?$ reviews/widgets [NC]**so, the caret (^) ensures that the url starts with widgets, while the dollar sign ensures that the redirect rule stops there (eliminating that pesky problem you encountered with the review pages also getting redirected). The ? just means that the trailing slash is optional.Hope that helps. If this solution isn't feasible, you could always hedge with rel="canonical" on the mydomain.com/widgets page and have that point to the proper page. That will at least help with Google.-Jason
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
-
Do I need multiple 301s to preserve SEO
Many years ago I created website www.original.com. Two years ago I redirected website www.original to www.neworiginal.comusing 301 redirects. I have now created www.rebranded.com. I want to maintain all SEO value. Should I redirect both www.original.comand www.new original.com to www.rebranded.com? Or do I only need to redirect one of them and if only one which one? If I need only to redirect one can I delete the other, why or why not. Of course the url are fictitious. I truly appreciate your help
Intermediate & Advanced SEO | | PhotoStl0 -
Selectively 301 redirects
Hi there: We are developing a pretty typical 301 redirection strategy. We basically are moving blog posts from a former sub-domain to the top level of our new designed site. We've pulled a site crawl of the old sub-domain and want to make sure we redirect any posts with a significant backlink profile to their current counterparts. Most other posts are just going to be redirected to the main 'front door' of our new blog. Is there a way to selectively redirect a certain number of posts and then 'globally' redirect everything else to a single URL? I would assume this would be a pretty common task, but can't find an easy way to do what we want to do.
Intermediate & Advanced SEO | | Daaveey0 -
301 Redirects... Redirect all content at once or in increments?
Hello, I have been reading a lot about site migration and 301s and sometimes get confused with conflicting suggestions from different sources... So, in a site migration. Should I 301 redirect all old URLs to the news at once or little by little? I've see this Google handout that suggests doing it all at once (minute 13)
Intermediate & Advanced SEO | | Koki.Mourao
https://plus.google.com/u/0/events/cfco632lor7bl55j3tg1g8332l0 But also have read the opposite in other forums...0 -
301 Redirecting Multiple Domains
I have several complete websites with blogs setup for different geo locations and was considering forwarding them all to one domain directly would greatly benefit ranking. The blogs are all linked together and that is where most of the links come from. Would I benefit in 301 Redirecting the domains?
Intermediate & Advanced SEO | | WindshieldGuy-2762210 -
301 redirect or rel=canonical
On my site, which I created with Joomla, there seems to be a lot of duplicated pages. I was wondering which would be better, 301 redirect or rel=canonical. On SeoMoz Pro "help" they suggest only the rel=canonical and dont mention 301 redirect. However, ive read many other say that 301 redirect should be the number one option. Also, does 301 redirect help solve the crawling errors, in other words, does it get rid of the errors of "duplicate page content?" Ive read that re-=canonical does not right? Thanks!
Intermediate & Advanced SEO | | waltergah0 -
I dont know what happened?!? Help!
Up until yesturday I was mainly getting entrances to my site through www.moondoggieinc.com/dog-harness.php like 60-70 a day After yesterday, it's dropped to one or two! I haven't made any major changes to the site? I don't know what happened! I am starting to feel really discouraged and don't know what to do! I have no clue what my next move should be in trying to get this site working well in organic search. I feel lost now, PLEASE help! Any suggestions on what to do with http://www.moondoggieinc.com would be a great help! I feel so lost! THANKS! Kristy O
Intermediate & Advanced SEO | | KristyO0 -
Need help or explanation on my site!
My site has suffered greatly since the recent Google update. I have done everything as suggested. I have had all bad links removed over 2 months ago. I have lowered keyword density (not easy since the keyword is in our company name!). I have rewritten various content and bolstered our existing content. What gives? What can I do? As an example the keyword, "maysville plumber" - I rank about 40th for this keyword. The first three pages are filled with websites with literally NO content or no added value. Maysville is a town of about 1k residents - there is no competition. Before the update I was #1 for years on this particular keyword. And this is the case with 35 other cities (mostly small cities, but a few larger ones). Please help me understand or suggest what I can possibly do at this point. We have hundreds of pages of unique content on each and every page. We have zero duplicate content (I have ran tests and crawlers). We have no fishy links. I have not gotten any messages from google on Webmasters. PLEASE HELP!! I asked a similar question a little while back and fixed all of the suggestions. My site is www.akinsplumbing.net.
Intermediate & Advanced SEO | | chuckakins0 -
How do I go about changing a 302 redirect to a 301.
Hello Friends! Thanks for viewing my question. Ok,My question today is How do I go about redirecting a 302 link to a 301 link. I understand the benefits of doing this as far as link juice and how the Search Engines views the two Re-Directs. I am wanting to know where I would start to do this. Thank you in advance for any help or suggestions!
Intermediate & Advanced SEO | | FrontlineMobility0