Suggestions in redirecting an old URL to new URL with parenthesis () ?
-
What should I use in .htaccess if I will redirect an old URL with parentheses to a new URL like below?
RedirectMatch 301 http://www.olddomain.com/buy/nike-shoes/kobe(7)/red http://www.newdomain.com/buy/nike-shoes/kobe(7)/red
Or
RedirectMatch 301 http://www.olddomain.com/buy/nike-shoes/kobe(7)/red http://www.newdomain.com/buy/nike-shoes/kobe(7)/red
-
So did that process of escaping the special characters solve your issue, esiow?
-
I'll try this one. Big help ThompsonPaul! I'll let you know if this works. Thanks a lot!
-
The successful way to accomplish this can depend a bit on your server configuration, esiow, but the most likely workable and reliable solution is to "escape" the non-standard URL characters. (Actually, the best solution would be to get rid of the unsafe URL characters altogether, but that's not what you asked )
.htaccess rewritedirect rules are essentially regular expressions or regexp. In regexp, many non-URL characters are used to format different commands. So having them as an actual URL character causes the redirect rule to try to process them as regexp instead of as just a URL character. Whew - hope that makes sense.
To tell the redirect rule to treat the non-standard character as an actual character instead of a command - you "escape" it by adding a "****" (without the quotes) in front of each character that could be a problem.
So:
RedirectMatch 301 http://www.olddomain.com/buy/nike-shoes/kobe(7)/red http://www.newdomain.com/buy/nike-shoes/kobe(7)/red
becomes:
RedirectMatch 301 http://www.olddomain.com/buy/nike-shoes/kobe***(7***)/red http://www.newdomain.com/buy/nike-shoes/kobe***(7***)/red
Give that a try in your .htaccess file and let us know if it works. if not, there may be a couple other options to try.
Hope that helps?
Paul
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
-
Moving content form Non-performing site to performing site - wihtout 301 Redirection
I have 2 different websites: one have good amount of traffic and another have No Traffic at all. I have a website that has lots of valuable content But no traffic. And I want to move the content of non-performing site to performing site. (Don't want to redirect) My only concern is duplicate content. I was thinking of setting the pages to "noindex" on the original website and wait until they don't appear in Google's index. Then I'd move them over to the performing domain to be indexed again. So, I was wondering If it will create any copied content issue or not? What should i have to take care of when I am going to move content from one site to another?
White Hat / Black Hat SEO | | HuptechWebseo0 -
How to resolve - Googlebot found an extremely high number of URLs
Hi, We got this message from Google Webmaster “Googlebot found an extremely high number of URLs on your site”. The sample URLs provided by Google are all either noindex or have a canonical. http://www.myntra.com/nike-stylish-show-caps-sweaters http://www.myntra.com/backpacks/f-gear/f-gear-unisex-black-&-purple-calvin-backpack/162453/buy?src=tn&nav_id=541 http://www.myntra.com/kurtas/alma/alma-women-blue-floral-printed-kurta/85178/buy?nav_id=625 Also we have specified the parameters on these URLs as representative URL in Google Webmaster - URL parameters. Your comments on how to resolve this issue will be appreciated. Thank You Kaushal Thakkar
White Hat / Black Hat SEO | | Myntra0 -
Can links from an old site raise DA for other site? Or just unethical?
So this may be an odd question. So a competing company went out of business. Their domain name is now available. So just for research purposes, would you ever or would it be unethical for a person to buy an expired competing domain name, and point it to another site to collect their link juice? The site was only a DA of 10, but not sure if one - its bad to buy a competing companies expired domain - and two - even though in the same industry, this would be bad to point it to another site or create a site from it. Just curious your thoughts.
White Hat / Black Hat SEO | | asbchris0 -
Partial Match Penalty Site - Move Portion & Redirect To New Site
So I have a site that currently has a partial match penalty from google, I have been working to get it removed...Bad SEO basically my site was submitted to a bunch of bad blog networks..Hopefully it gets lifted soon as we remove and disavow links. That said I was planning on moving a portion of my site to a new site since its not really the focus of the site anymore however still pays the bills. I have also have been building it more of a network of sites..So If I do that and 301 redirect the pages I moved, will the penalty carry? On the current site I planned on using Rel no follow to any links that I may change in the header/menus etc.. Some of these pages I believe have the penalty while others dont. I really just dont want to screw anything else up more then it is? My biggest fear is that its perceived as a blackhat method or something like that? Any thoughts?
White Hat / Black Hat SEO | | dueces0 -
2 Questions about 301 Redirects
So I have a couple of questions about 301 redirects: Do Google penalties EVER pass through a 301? I've done 20+ domain 301s in the last year and have yet to see it happen, but the other day I read a an article (or maybe it was a QA post?) that suggested doing 302s to avoid transferring penalties. Has anyone seen any authoritative information regarding this? I 301'd a domain in February that another SEO firm had built a lot of spammy links and I began building contextual links for it at a very slow rate (like 10 or so a month). Within a month, my domain authority was a 26 on the new domain and my inbound links were non existent. By month 2, my links were 70k and domain authority was 34. By month 3, down to 25k inbound links and domain authority of 29, where it has settled for the last 3 months despite some really high quality links. My question (don't worry it's coming), is does anyone have any clue why my links shot up so quickly and then dropped? I'm assuming the 301 links kicked in and then only about 45% ended up 'sticking'?? Thanks in advance
White Hat / Black Hat SEO | | BrianJGomez0 -
Why do websites use different URLS for mobile and desktop
Although Google and Bing have recommended that the same URL be used for serving desktop and mobile websites, portals like airbnb are using different URLS to serve mobile and web users. Does anyone know why this is being done even though it is not GOOD for SEO?
White Hat / Black Hat SEO | | razasaeed0 -
302 redirects - redirecting numerous domains into main primary domain
302 Redirects - We are a digital agency carrying out some SEO analysis for a potential client. The client has bought over 150 different domains and redirected (302) them into his main domain. The domains were bought up based on relevant industry keywords and protection. On first instance this seems like a Black hat technique that Google would most definitely punish - buying up domains and redirecting them to main website. Does anyone have any thoughts on this? Thanks...
White Hat / Black Hat SEO | | Seanbain0 -
Closing down site and redirecting its traffic to another
OK - so we currently own two websites that are in the same industry. Site A is our main site which hosts real estate listings and rentals in Canada and the US. Site B hosts rentals in Canada only. We are shutting down site B to concentrate solely on Site A, and will be looking to redirect all traffic from Site B to Site A, ie. user lands on Toronto Rentals page on Site B, we're looking to forward them off to Toronto Rentals page on Site A, and so on. Site A has all the same locations and property types as Site B. On to the question: We are trying to figure out the best method of doing this that will appease both users and the Google machine. Here's what we've come up with (2 options): When user hits Site B via Google/bookmark/whatever, do we: 1. Automatically/instantly (301) redirect them to the applicable page on Site A? 2. Present them with a splash page of sorts ("This page has been moved to Site A. Please click the following link <insert anchor="" text="" rich="" url="" here="">to visit the new page.").</insert> We're worried that option #1 might confuse some users and are not sure how crawlers might react to thousands of instant redirects like that. Option #2 would be most beneficial to the end-user (we're thinking) as they're being notified, on page, of what's going on. Crawlers would still be able to follow the URL that is presented within the splash write-up. Thoughts? We've never done this before. It's basically like one site acquiring another site; however, in this case, we already owned both sites. We just don't have time to take care of Site B any longer due to the massive growth of Site A. Thanks for any/all help. Marc
White Hat / Black Hat SEO | | THB0