开发者

Use htaccess to change file type, works on some servers, others it prompts download of file

I'm using htaccess to change a file extension from gif to php but it does not change on a particular test server, instead it prompts a download for the gif file which reveals the php.

The .htaccess file is in the same directory as the gif. The code looks like this, any ideas?

开发者_如何学JAVA<Files trackme.gif>

ForceType application/x-httpd-php

</Files>


Try SetHandler instead of ForceType:

SetHandler application/x-httpd-php
# or
SetHandler application/x-httpd-php5
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜