I have dirty url like this :
http://morvaridtour.com/viewtour.php?id=10&title=name-of-tour
10 And name-of-tour is dynamic values
i'm trying to clean that url like this
I have dirty url like this :
http://morvaridtour.com/viewtour.php?id=10&title=name-of-tour
10 And name-of-tour is dynamic values
i'm trying to clean that url like this
In your .htaccess
file, try something similar like below:
RewriteEngine on
RewriteRule ^name-of-tour/([0-9]+)/(.*)/?$ viewtour.php?id=$1&title=$2 [QSA]
Where $1
is first variable contains only integer ([0-9]+)
and $2
(title) is second var (.*)
that accept all characters