Can I make a universal 301 redirect rule for my site?
-
I.e. I switch shopping carts and every page has the same path/name but now ends in .php instead of .htm.
-
If you have mod_rewrite enabled on your server you could try something like this in your .htaccess file:
RewriteCond %{REQUEST_URI} ^(.).htm$
RewriteRule ^(.) /$1.php [R=301,L] -
You can use Excel formulas to generate a list with all your URLs with .php....
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
-
How to Diminish the spam score of the site?
I AM HERE TO DISCUSS MY PROBLEM AFTER THE GOOGLE CORE UPDATE OF OCTOBER MONTH MY WEBSITE SPAM SCORE IS INCREASING RAPIDLY HOW TO CONTROL THIS PROBLEM PLEASE HELP ME ASAP MY WEBSITE NAME IS EGYPT DIRECT
Link Building | | aprase1 -
EHow - does anyone have a writer that they can recommend?
A client specifically wants an a guide posted on ehow related to their products. I have submitted an application and it has not been approved. Does anyone have a writer they would recommend?
Link Building | | Packaging-Group0 -
Links from sites with iffy link profiles?
So the site http://www.cadenas.de/ appears to have good decent scores from the various Moz ranks, but when I check out the site in OSE there are a lot of really sketchy links that jump out, online pharmacy/drug type links. I should also add that the negative links are seemingly going to a weird blog deep in the site and only appear when I select all links to the root domain in OSE. Everything about the site appears very legitimate except for the link profile which has me nervous. Would you guys pursue a link from this site?
Link Building | | CJ50 -
Backlinks that redirect to your site
Hi all, I just wanted to ask you all about backlinks that redirect to your site. I recently used Link Detox Tools to carry out a link analysis. However, some of our backlinks are redirecting to our homepage. Is this ok? Why is this happening? Thanks guys!!!
Link Building | | AAttias0 -
Best way to set up a support site - sub domain, separate site or com/support?
My company is setting up our support site. It has been suggested that we set it up as a separate domain - www.company-support.com, rather than setting it up as a sub-domain (www.support.company.com) or the usual www.company.com/support. The person who proposed this believes it wlll create link juice, but i wonder if splitting the traffic will create more harm than good? Opinions please!
Link Building | | googilvie0 -
How do you optimize your site for surrounding areas?
For example, If I am optimizing a site for a dentist in West Palm Beach, Florida (the primary city) how do I ensure I am also optimizing my site for the smaller cities/towns that are part of West Palm Beach like Royal Palm Beach, Wellington etc.? If I am using "West Palm Beach" in my site and page titles etc., how do I also rank for the smaller cities? What are the basic tactics in terms of on-site and linking? For instance, lets say I offer Botox in West Palm Beach...how do I also optimize for Wellington, Royal Palm Beach and other local cities? Do I really have to create unique Botox content for each city? Thanks!
Link Building | | RickyShockley0 -
Please take a look at the SEO of my site
Hello, I was wondering if you guys could analyze my site and give me pointers on how I could improve it's SEO. I'm a health and wealth coach, NLP coach, and life coach in the Boise, Idaho area. bobweikel.com Also, any link building advice you can give would be great. Here's my backlink criteria Age (as old as possible) A lot of unique content A clean site Backlinks going to that site Facebook followers Which of course means high search engine rankings Thanks
Link Building | | BobGW0 -
Site content creation
I have a new customer that wants to build a comprehensive website to provide dental health information. However, he's a busy dentist and can't develop all the content himself. He particularly likes what mercola.com (http://articles.mercola.com/sites/current.aspx or http://blogs.mercola.com/sites/vitalvotes/default.aspx) is doing to provide content from other sources. At first I thought this could be a good thing and that we could setup some Google Alerts that would alert us to new content related to specific topic areas and then post excerpts and links to the original source of the content. But now I'm concerned that we'll get penalized for this. Can you give me some advice on how to go about getting new/fresh content on a new website that doesn't require someone to write it all themselves? Thank you!
Link Building | | ChristiMcGinley0