I want to make a redirect url
From
http://abc.redirect.in/admin/index.php?controller=class&action=add
To
http://abc.redirect.in/admin/class/add
Any idea?
Want to remove text
http://abc.redirect.in/admin/
index.php?controller=class&action=add
I want to make a redirect url
From
http://abc.redirect.in/admin/index.php?controller=class&action=add
To
http://abc.redirect.in/admin/class/add
Any idea?
Want to remove text
http://abc.redirect.in/admin/
index.php?controller=class&action=add
You can use this code in your /admin/.htaccess file:
RewriteEngine On
RewriteBase /admin/
RewriteCond %{THE_REQUEST} /admin/index\.php\?controller=([^\s&]+)&action=([^\s&]+) [NC]
RewriteRule ^ %1/%2? [R=302,L,NE]
# internal forward from pretty URL to actual one
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([^/.]+)/([^/.]+)/?$ index.php?controller=$1&action=$1 [L,QSA]
http://test.localhost/admin/pjAdmin/pjActionLogin in browser? Are you seeing this pretty URL. Then 2nd rule will route it back /admin/index.php. Do you have other rules also in this .htaccess? Or is there any other htaccess?/admin/.htaccess