That is my .htaccess
:
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?rt=$1 [L,QSA]
It recognizes which controller should be open (MVC-my own framework) so domain.com/about
goes to aboutController
And when the address is domain.com/prod/category/product
I want the address to be domain.com/category/product
to hide controller.
Is it possible?
I want that rule just for domain.com/prod
and domain.com/cat
Easy, just set a RewriteCond
for prod
and cat
like this:
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} ^/(prod|cat)
RewriteRule ^(.*)$ index.php?rt=$1 [L,QSA]