I would just create the file and in that file declare a few global variables like
i usually put this file one level above my web root folder.
<?php
define('DB_HOST','localhost');
define('DB_USER','username');
define('DB_PASSWORD','password');
?>
then in your project just do this
<?php
require_once('database.inc.php');
//or something like
require_once('C:/Program Files/Apache/Apache2/database.inc.php');
//just make sure you use the path to the file.
$dblink=mysql_connect(DB_HOST,DB_USER,DB_PASSWORD);
?>