i want change this URL: domain.com/directory/news?id=80&title=news-title
to this: hdomain.com/directory/news/news-title
how can I do this? my htaccess also has a lot other rewrites. look:
Options +FollowSymLinks
RewriteEngine On
RewriteBase /directory/
RewriteRule ^referenzen/([^.]+)/$ $1.php?rw=1 [QSA,L]
RewriteCond %{QUERY_STRING} !^rw=1
RewriteRule ^brands.php$ http://domain.com/directory/referenzen/brands/$1 [R=301,L]
RewriteRule ^referenzen/([^.]+)/$ $1.php?rw=1 [QSA,L]
RewriteCond %{QUERY_STRING} !^rw=1
RewriteRule ^entertainment.php$ http://domain.com/directory/referenzen/entertainment/$1 [R=301,L]
RewriteRule ^referenzen/([^.]+)/$ $1.php?rw=1 [QSA,L]
RewriteCond %{QUERY_STRING} !^rw=1
RewriteRule ^tourism.php$ http://domain.com/directory/referenzen/tourism/$1 [R=301,L]
RewriteCond %{THE_REQUEST} index(\\.php)?
RewriteRule ^index(\\.php)?$ http://domain.com/directory/ [R=301,L]
RewriteCond %{THE_REQUEST} ^[A-Z]{3,}\s([^.]+)\.php [NC]
RewriteRule ^ %1 [R,L,NC]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^\.]+)$ $1.php [NC,L]
I don't know if it's all correct but it is doing what it should do. ;-) I only need the new rule to rewrite the dynamic url for the news.
Hope anyone can help - thanks!
You can rewrite all links to one php file and with reg. load templates that you need. I can help you.