below i have a clean form...
- Code: Select all
<form action="http://www.my-domain.com/search.php" method="get">
<input type="text" name="q" id="search" value="" />
</form>
if I search something example cricket or greg timmons... then the page goes to
http://www.my-domain.com/search.php?q=cricket
or
http://www.my-domain.com/search.php?q=greg+timmons
but I want the URL to be
http://www.my-domain.com/search/cricket/
and
http://www.my-domain.com/search/greg timmons/ (the space here could be replaced by a + or an _ )
any idea how to accomplish this... I tried
- Code: Select all
RewriteRule ^search/([a-zA-Z0-9_-]+)$ search.php?q=$1 [NC]
RewriteRule ^search/([a-zA-Z0-9_-]+)/?$ search.php?q=$1 [L,NC]
but no go... even the direct url examples like
http://www.my-domain.com/search/ANYTHING-HERE/
dont open and give a not found error ?
please help.