.htaccess - Rewrite rule based on query string -


i'm trying redirect base url (www.example.com) requests have particular query string (when option com_estateagent).

i've tried following syntax:

rewriteengine on rewritebase / rewritecond %{query_string} ^option=com_estateagent$ rewriterule .* index.php [r=301, l] 

but gets ignored.
suggestions?

edit
url want change this:
http://www.example.com/subdirectory/index.php?option=com_estateagent...

i don't think need rewritecond directive, wouldn't work?

rewriterule ^/.*option=com_estateagent /index.php[r=301,l] 

Comments

Popular posts from this blog

php - mySql Join with 4 tables -

css - Text drops down with smaller window -

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -