I'm trying to rewrite a couple of urls that look like this: domain.com/?q=blabla&click=start domain.com/?q=blabla+blabla2&click=start I want them to redirect to domain.com/search/blabla I tried ^?q=blabla http://www.domain.com/search/blabla [R=301,L] but that will show a 500 error. Also tried ^\?q=blabla http://www.domain.com/search/blabla [R=301,L] I tried some results on Google but didn't work. I have no idea how to get this to work, i did see lots of ideas and suggestions with urls that have the question mark after index.php for example but none where the question mark starts right after the / Any htaccess pros who know how to tackle this one? Thanks in advance
Try this one: (just off the top of my head) RewriteRule ^search/([^/\.]+)/?$ ?q=$1&click=start [R=301,L] Code (markup):