Forum Moderators: phranque

Message Too Old, No Replies

Restricting PHP Files from running

Any way in htaccess to do that?

         

mikewalterz

7:28 pm on Jan 2, 2007 (gmt 0)

10+ Year Member



Hello,
I was just wondering if there was a way in htaccess to restrict php files from running?

So the user could upload .php or .php3 files, but they wouldn't run on the server since its a security issue.

Thanks again!

coopster

7:30 pm on Jan 2, 2007 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



Welcome to WebmasterWorld, mikewalterz.

You could turn the PHP engine [php.net] off.

mikewalterz

7:42 pm on Jan 2, 2007 (gmt 0)

10+ Year Member



Much appreciated :D

Thanks.

pixeltierra

4:26 pm on Jan 4, 2007 (gmt 0)

10+ Year Member



You could store files in a directory above the public_html or you could use a htaccess file to deny all access to the directory you store them in.