I need rewrite this url http://adresa.com/article.php?act=view&id=1113 to http://adresa.com/view/1113
I make it with mod_rewrite in .htaccess but it doesn’t work.
RewriteBase /
RewriteCond %{QUERY_STRING} ^act=([^&]+)$
RewriteRule ^article\.php$ %1.html? [R=301,L,NE]
RewriteRule ^([^/]+)\.html article.php?rw=1&act=$1 [L,QSA]
RewriteRule ^([^/]+)/{1}([^/.]+)\.html article.php?rw=1&act=$1&id=$2 [L,QSA]
Can somebody help me please?
Here’s the solution (with proper line-separation to avoid confusion (RewriteCond is valid for only one following RewriteRule, so put a blank line after to avoid confusion)):