: Apache .htaccess - All URLs with different parameters to ONE redirect I need some help with .htaccess redirect. http://www.example.de/test-music.html?p1=1&p2[test]=23 http://www.example.de/test-music.html?p1=6&p2[test3]=5
I need some help with .htaccess redirect.
www.example.de/test-music.html?p1=1&p2[test]=23 http://www.example.de/test-music.html?p1=6&p2[test3]=5
ALL of them need to be redirected to ...
www.example.de/music/
... without taking care of any parameters - can you help me?
More posts by @Sue5673885
2 Comments
Sorted by latest first Latest Oldest Best
Very easy, this is something you can easily find and figure out yourself.
# Check if the url STARTS WITH (is what the ^ does) '/test-music'
RewriteCond %{REQUEST_URI} ^/test-music
# redirect it, 301 style, Last line (we go away, no need to do the rest of the htaccess)
RewriteRule ^(.*) /music/ [L,R=301]
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.