apache - htaccess - append html or php based on URL -
i have following rules adds .html requests if user navigates www.mysite.com/support, see www.mysite.com/support.html page:
rewritecond %{request_filename} !-d rewritecond %{request_filename}\.html -f rewriterule ^(.*)$ $1.html how can change specific urls, adds .php instead of .html:
- /support => should go www.mysite.com/support.php
- /contact => should go www.mysite.com/contact.php
- /everything else => should go www.mysite.com/...html
thanks.
i change .htaccess to:
rewritecond %{request_filename} !-d rewritecond %{request_filename}\.html -f rewritecond %{request_filename}\.php -f rewriterule ^support /support.php [l] rewriterule ^contact /contact.php [l] rewriterule ^(.*)$ $1.html
Comments
Post a Comment