What are the best strategies to organize a htaccess full of 301 re-directs
-
I have a client with a htaccess file that is a total mess!
What are the best practices to organize all the re-directs, and make it more manageable in the future.
Any resources would be appreciated.
-
Do you have root access to the server? If you do then a rewrite map is a lot faster then a bunch of rewrite rules & conditions.
http://httpd.apache.org/docs/2.0/mod/mod_rewrite.html#rewritemap
You can always just add comments with the hash tag: # what each thing does and group them. That would be cleaner.
-
We have a site that is categorized by folder so we place separate .htaccess files in each folder... that keeps them relatively small instead of placing all of redirects in the root.
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
-
SEO strategies specifically for saas companies
For location specific businesses there are many tactics to locally optimize your business letting them rank higher than large companies. Are there any tactics/strategies specifically for saas companies?
Intermediate & Advanced SEO | | alexadedmon0 -
Best strategy to follow for a single service site
Can anyone share what they feel is the best strategy to follow for a single service site? Would you optimise and target the homepage for the primary service they offer or target a page one level lower and leave the homepage to target the Brand name? Links to any references or case studies would also be greatly appreciated, thank you!
Intermediate & Advanced SEO | | Marketing_Today0 -
What Are Latest Internal Linking Strategies?
I have been doing a little research, but all the articles are really old. Even the Moz site page is pretty old. So I am wondering, has the strategy changed? Is it OK to still use internal links with your keywords in them? Do you have multiple links on a page? What about a blog post? Do you no follow? What are the thoughts out there on this?
Intermediate & Advanced SEO | | netviper0 -
Schema.org for Organization Logos
Hi, We have 4 different sites on four different domains. each domain serves a different market and sells different products. However, all 4 sites have the same logo. we are thinking of implementing the logo schema.org for our logo - http://googlewebmastercentral.blogspot.ca/2013/05/using-schemaorg-markup-for-organization.html Does any one know if Google might see the identical logos (even if Google cant actually see an Image like a human) for different domains as something spammy? Many thanks
Intermediate & Advanced SEO | | CeeC-Blogger0 -
301 or 302 Redirects to Mobile Site
When it's detected that a mobile device is accessing the site it has the ability to redirect from www.example.com to m.example.com. Does it make more sense to employ a 301 or 302 redirect here? Google says a 301 but does not explain why (although usually I stick to "when in doubt, 301") . It seems like a 302 would prevent passing link juice to the mobile site and having mobile-optimized results also showing up in Google's index. What is the preference here?
Intermediate & Advanced SEO | | SEOTGT0 -
Best practice?
Hi there, I have recently written an article which I have posted on an online newspaper website. I want to use this article and put it on my blog also, the reason the article will be placed on my blog is to drive users from my email marketing activities. Would it simply be best practice to disallow Google from crawling this page? or put a rel canonical on the article placed on my blog pointing to the article placed on the online newspaper website? Thanks for any suggestions
Intermediate & Advanced SEO | | Paul780 -
Is it possible to 301 re-direct an entire subfolder on a subdomain?
So, for example, subdomain.domain/folder subdomain.domain/folder2 Is it possible to set up a 301-re-direct for an entire folder on a subdomain? If so, how? What is the correct code for this?
Intermediate & Advanced SEO | | nicole.healthline0 -
What do you think about this strategy?
I am new to SEO but have been hired to handle the SEO for a martial arts school. They had previously attained top three rankings primarily using nofollow on every link on the homepage except footer links which had anchor text of their keywords pointing to their second tier pages. Each of those second tier page also had all nofollow except a single footer link that had a keyword anchor text link going back to the home page. Seemed to work for them. I was going to keep it as as well as focus on creating about 10 separate wordpress blogs. They want to give each blog to a student who will post daily and from each post link to their site via anchor text. Anything wrong with this? Thanks Wiliam
Intermediate & Advanced SEO | | whorneff3100