I actually do DB settings in a PHP code block, ala:
db_settings.php
<?php
$server="myserver.com";
$username="me";
$password="password";
?>
Then just do a require statement in your PHP scripts and use the variable names in your connect string.
This way, if someone does call your db_settings.php file, nothing is displayed...the script returns nothing to the browser.
Sean Shrum