PDA

View Full Version : Private PHP!


silentpeace
20th January 2006, 21:30
Can anyone tell me how to set up new site that after disabling PHP scripts, if client uploads php,instead of code on his site shows up some kind of error?:rolleyes:

till
20th January 2006, 22:41
Do you mean that a client shall not be able to upload php files to a site and get an error instead?

silentpeace
24th January 2006, 09:12
I mean when he uploads php site and after that when someone tries to go to his site,lets say "index.php",visitor gets some kind of error page instead of php code of that "index.php".
Thnx for prompt answer. :)

falko
24th January 2006, 21:19
You could put this into the "Apache Directives" Field of ISPConfig:

<Files ~ '.php$'>
Order allow,deny
Deny from all
Allow from none
</Files>
<Files ~ '.phps'>
Order deny,allow
Allow from all
</Files>

It doesn't display an error for PHP files, but at least it doesn't show the source code.