0

我想将php扩展的所有文件重写为html

像这样的例子

www.mydomain.com/file.php to www.mydomain.com/file.html

我把这段代码放在我的 htaccess 上

AddHandler application/x-httpd-php .php .html .htm 

但它不会工作

我能做什么工作这段代码

谢谢

4

1 回答 1

0
RewriteEngine on
RewriteBase /
RewriteRule ^(.*)\.html$ $1.php [R=permanent] 
于 2012-12-26T10:45:09.023 回答