Peter Falkenberg Brown Posted July 30, 2014 Share Posted July 30, 2014 Hi All, I'm changing the section url of one my sections at the Significato Journal, and I'm stuck on getting the .htaccess syntax to work. I've tried adding this to the .htaccess file, just below the "redirect to www" section (which I'm not using) -- RewriteRule ^/columns/culture-of-heart/(.*)$ http://significatojournal.com/columns/culture-of-kindness/$1 [R=301,L] I also tried adding a slash before the $ in the source, i.e. RewriteRule ^/columns/culture-of-heart/(.*)/$ http://significatojournal.com/columns/culture-of-kindness/$1 [R=301,L] Neither worked. When I change the url of the section from 'culture-of-heart' to 'culture-of-kindness', and then enable one of the rules above, and then click on an article page, e.g. http://significatojournal.com/columns/culture-of-heart/the-omnipresent-embrace/ it fails with a page not found. (Note that currently, the old url is still active, so you won't see an error.) Does anyone have any suggestions about the syntax? I don't want to have to create 301s for all of my essays under that section, and would rather use rewrite magic. Thanks! Peter Link to comment Share on other sites More sharing options...
teppo Posted July 30, 2014 Share Posted July 30, 2014 Does this work for you? RewriteRule ^columns/culture-of-heart/(.*)$ http://significatojournal.com/columns/culture-of-kindness/$1 [R=301,L] Link to comment Share on other sites More sharing options...
Peter Falkenberg Brown Posted July 30, 2014 Author Share Posted July 30, 2014 Dear Teppo, Does this work for you? RewriteRule ^columns/culture-of-heart/(.*)$ http://significatojournal.com/columns/culture-of-kindness/$1 [R=301,L] Thank you! Removing that one little preceeding slash did the trick. Now it works like a charm. Sigh. Apache rewrite rules give me a headache. Problem solved, and thanks again! Peter Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now