Hi. As with any good programming practice i use includes to handle such things as database variables and the like.
I have a file called conf.inc which contains variables like:
$location = "localhost";
$databasename = "mydb";
$databaseuser = "username";
$databasepasswd = "xxxxxxxxx";
then of course i call it within my script whenever i need to connect to database.
PROBLEM: - if someone knows the name of my include script and types it into their browser address bar like
http://www.mydirectory.com/conf.inc
The include completely displays all the information to the screen. As you can see, this is bad, bad, bad, bad. How do i hide it so this does not happen.