Lance O. Posted August 5, 2016 Share Posted August 5, 2016 I know this question has been asked before, but in this case, I don't want to use a PW module. I have added redirects at the very top of my .htaccess file, formatted like the examples below: RedirectMatch 301 /onsite2/ http://domain.com/ Redirect 301 /onsitefocusedthanks/ http://domain.com/club/ Unfortunately, the redirects are going to: http://www.domain.com/onsite/ (404 page not found) http://www.domain.com/club/?it=onsitefocusedthanks/ Is there a way to removed the "?it=index.html" and prevent these redirect errors? Link to comment Share on other sites More sharing options...
teppo Posted August 5, 2016 Share Posted August 5, 2016 Since you're using Redirect / RedirectMatch, both of which are features of mod_alias, there's no way that I'm aware of to do this. What you should do is move this redirect after the "RewriteEngine On" part of the .htaccess file and use a RewriteRule (mod_rewrite): RewriteRule ^onsite2/$ http://domain.com/ [R=301,L] RewriteRule ^onsitefocusedthanks/$ http://domain.com/club/ [R=301,L] 2 Link to comment Share on other sites More sharing options...
Lance O. Posted August 5, 2016 Author Share Posted August 5, 2016 @teppo, thanks for the very quick response. I've implemented these changes and everything is working smoothly now. Thank you!!!! 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