hankknight
asked on
Making scripts NON EXECUTABLE with .htaccess
Hello,
How are you?
I have a directory on my website that I need to make available for public FTP uploads / downloads. I do NOT want anything in that directory to be executable.
.PHP, .pl, cgi and .sh SHOULD ALL be treated as plain text.
Is there something I can put in my .htaccess file to secure this directory?
Thanks!
How are you?
I have a directory on my website that I need to make available for public FTP uploads / downloads. I do NOT want anything in that directory to be executable.
.PHP, .pl, cgi and .sh SHOULD ALL be treated as plain text.
Is there something I can put in my .htaccess file to secure this directory?
Thanks!
php_admin_flag engine off
Sorry that should be
php_value engine off
AddType text/plain .html .htm .shtml .php
php_value engine off
AddType text/plain .html .htm .shtml .php
ASKER
Thanks!
So something like this then:
php_value engine off
AddType text/plain .html .htm .shtml .php .sh .cgi .pl .c
But, I could be missing something so is there a way to set EVERTHING except:
.png
.gif
.jpg
.psd
.tif
.ai
.pdf
.eps
To text/plain ?
So something like this then:
php_value engine off
AddType text/plain .html .htm .shtml .php .sh .cgi .pl .c
But, I could be missing something so is there a way to set EVERTHING except:
.png
.gif
.jpg
.psd
.tif
.ai
.eps
To text/plain ?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.