.htaccess - HTACCESS VARIABLE Regarding issue -
i have website, in making url clean of htaccess. example. example.com/fathers/?n=name open example.com/father/name
i doing of below code.
rewritecond %{request_filename} !-f rewritecond %{request_filename} !-d rewriterule ^father/([^\/]+)/(\/|)$ fathers/index.php?n=$1 [qsa] rewritecond %{request_filename} !-f rewritecond %{request_filename} !-d rewriterule ^father/([^\/]+)(\/|)$ fathers/index.php?n=$1 [qsa]
my question is, how make
example.com/anythinghere/?n=name open example.com/anythinghere/name
how can this?
you can use rule in .htaccess
:
rewriterule ^anythinghere/([^/]*)$ /anythinghere/?n=$1 [l]
just make sure clear cache before testing it.
Comments
Post a Comment