I have a site with a lot of url’s like this
www.example.com/this_has_some_meaning.php
Now I learned that for SEO reasons it is better to use
www.example.com/this-has-some-meaning.php
Can i, using htaccess, redirect all the url’s from the old to the new, using some kind of regex?
2
Answers
You can use these 2 rules in your .htaccess:
Use given code
In the given code developer target 5 sites separated by “|”