.htaccess, get parameters together?

57 views Asked by At

/index.php?user=username TO /username

AND

/index.php?page=settings TO /settings

Please help me, suggest solutions for .htaccess or PHP, would be very grateful!

1

There are 1 answers

0
Uday Hiwarale On BEST ANSWER

change .htaccess code to

RewriteBase /

RewriteEngine On
RewriteBase /

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule /(.*)$ index.php?user=$1
RewriteRule /(.*)$ index.php?page=$1