* Thus wrote Harlequin:
> Another day another problem. This time it appears that users are able to
> enter their details but I get a query execution error with the following
> section of code:
>
> /* Verify Login */
> $sql = "SELECT UserFirstName,UserID,UserPassword FROM RegisteredMembers
> WHERE UserID='$_POST[TXT_UserID]'";
> $result = mysql_query($sql) or die ("couldn't select database");
> $num = mysql_num_rows($result);
> if ($num == 1) //Login Name Was Found
> {
> $sql = "SELECT UserID FROM RegisteredMembers
> WHERE UserID='$_POST[TXT_UserID]'
> AND password=UserPassword('$_POST[TXT_UserPassword]')";
> $result2 = mysql_query($sql) or die("Couldn't execute query #2.");
>
> The next to last line is bugging me though. "AND password= etc. because I
> have a variable declared earlier in the logon page for TXT_UserPassword and
> the UserPassword column exists but where in the hell is "password"...?
Look at your table structure.
>
> Is this another of MySQLs "on the fly" variables...?
no.
Curt
--
First, let me assure you that this is not one of those shady pyramid schemes
you've been hearing about. No, sir. Our model is the trapezoid!
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php