php - How to change URL with htaccess -


i have code in htaccess file showing company profile:

rewriterule ([a-za-z0-9_+-]+)\/home\ view_details.php 

and code working fine url

http://www.example.com/zoom-international-fcz-/home.html 

now need rewrite url, not need add home.html, , zoom-international-fcz not static string, it's coming dynamically....

http://www.example.com/zoom-international-fcz/ 

example of dynamic rewrite rule

options +followsymlinks rewriteengine on rewriterule ^files/([^/]+)/([^/]+).zip /download.php?section=$1&file=$2 [nc] 

would allow present link as..

http://site.pl/files/games/file.zip

the 2 regular expressions in () put $1 , $2 , these params available in $_get variable on download.php site.


Comments