[thelist] php and my sql

Todd ToddManaze at ev1.net
Tue Jun 19 19:09:45 CDT 2001


I am trying to connect to mySQL but i am having trouble.

$user = "manaze";
$pass = "password";
$db =  "manaze";
$link = mysql_connect( "localhost", $user, $pass );
if ( ! $link )
 die( "Couldnt Connect" );
print "connected<p>";
mysql_select_db( $db)
 or die( " couldnt open $ db: " .mysql_error() );
print " succesfully selected database \"$db\"<p>";
mysql_close( $link );




----------------------------------------------------------------
Todd Manaze           
www.manaze.8m.com   
[Design | Hosting | Flash | Branding | Illustration]
www.brewermc.com
Web solutions for small business





More information about the thelist mailing list