It helps to say what sort of trouble you're having; i.e., provide symptoms, exact text of error messages, etc.
miguel On Fri, 26 Apr 2002, Randum Ian wrote: > Hi all, Im having trouble with this code, can anyone help? > > --- > > <?php // db.php > > $dbhost = "localhost"; > $dbuser = "dancepo_db"; > $dbpass = "database"; > > function dbConnect($db="dancepo_db") { > global $dbhost, $dbuser, $dbpass; > > $dbcnx = @mysql_connect($dbhost, $dbuser, $dbpass) > or die("The site database appears to be down."); > > if ($db!="" and !@mysql_select_db($db)) > die("The site database is unavailable."); > > return $dbcnx; > } > ?> > > --- > > Cheers, Ian. > --- > Randum Ian > DJ / Reviewer / Webmaster, DancePortal (UK) Limited > [EMAIL PROTECTED] > http://www.danceportal.co.uk > DancePortal.co.uk - Global dance music media > > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php