RE: stupid error, please kick me (and send me a solution)

From: Date: Mon, 03 Jun 2002 22:39:39 +0000
Subject: RE: stupid error, please kick me (and send me a solution)
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-100484@lists.php.net to get a copy of this message
It would also appear you are missing a closing ) at the end of the '$query=...' line. You have two opening backets and only one closing. Greg -----Original Message----- From: Bruce Lewis [mailto:blewis1@wi.rr.com] Sent: Tuesday, 4 June 2002 7:50 To: jslootbeek@clarku.edu; mysql; php-general Subject: Re: stupid error, please kick me (and send me a solution) Your missing your closing "}" at the end of the else statement. ----- Original Message ----- From: "Jule Slootbeek" <jslootbeek@clarku.edu> To: "mysql" <mysql@lists.mysql.com>; "php-general" <php-general@lists.php.net> Sent: Monday, June 03, 2002 5:09 PM Subject: stupid error, please kick me (and send me a solution) > Hey guys, > i'm getting this error with the following sql script using php: > --error-- > Warning: Supplied argument is not a valid MySQL-Link resource in > /var/www/phpquiz/register_user.php on line 12 > --error-- > > --script-- > $link_glob = "mysql_connect('$host_glob', '$un_glob', > '$pw_glob')"; > $query = "INSERT INTO user values('0', '$fname', '$lname', > '$email', > '$username', PASSWORD('$password')"; > $result = mysql_db_query('$db_glob', '$query', $link_glob'); > if (!$result) { > echo "<font size=+1>Your Information could not be entered into the database, > Please contact the <a > > href=mailto:$webmaster>webmaster</a>.</font><br><br>" > . mysql_errno() . > ": " . mysql_error() . "<br><br>"; > } else { > echo "<font size=+1>Your Information has successfully been entered into the > database!</font><br>"; > > -- > Jule Slootbeek > jslootbeek@clarku.edu > > http://blindtheory.cjb.net > > > > --------------------------------------------------------------------- > Before posting, please check: > http://www.mysql.com/manual.php (the manual) > http://lists.mysql.com/ (the list archive) > > To request this thread, e-mail <mysql-thread110862@lists.mysql.com> > To unsubscribe, e-mail <mysql-unsubscribe-blewis1=wi.rr.com@lists.mysql.com> > Trouble unsubscribing? Try: > http://lists.mysql.com/php/unsubscribe.php > > --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <mysql-thread110863@lists.mysql.com> To unsubscribe, e-mail <mysql-unsubscribe-greg.lawrie=netadvantage.com.au@lists.mysql.com> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

« previous php.general (#100484) next »