Date: 09/15/01
- Next message: swm <email protected>: "[PHP-DEV] Bug #13314 Updated: Warning: Supplied argument is not a valid MySQL result resource"
- Previous message: Andi Gutmans: "Re: [PHP-DEV] Re: Bug #13304 Updated: string comparisons not working as expected"
- Next in thread: swm <email protected>: "[PHP-DEV] Bug #13314 Updated: Warning: Supplied argument is not a valid MySQL result resource"
- Reply: swm <email protected>: "[PHP-DEV] Bug #13314 Updated: Warning: Supplied argument is not a valid MySQL result resource"
- Reply: rex <email protected>: "[PHP-DEV] Bug #13314 Updated: Warning: Supplied argument is not a valid MySQL result resource"
- Reply: rex <email protected>: "[PHP-DEV] Bug #13314 Updated: Warning: Supplied argument is not a valid MySQL result resource"
- Reply: mfischer <email protected>: "[PHP-DEV] Bug #13314 Updated: Warning: Supplied argument is not a valid MySQL result resource"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
From: rex <email protected>
Operating system: Red Hat Linux 7.1
PHP version: 4.0.6
PHP Bug Type: MySQL related
Bug description: Warning: Supplied argument is not a valid MySQL result resource
Background: I am running RH7.1 with MySQL 3.23, PHP-Nuke 5.0, and phpBB
1.4.1 (both Nuke and the BB are using the same database). After reading
through ticket number 10368, I removed PHP4.0.4, and compiled 4.0.6 using
--with-mysql=/usr/ --with-apxs
I continue to get the following error:
Warning: Supplied argument is not a valid MySQL result resource.
The code that produces this error is this:
function cookiedecode($user) {
global $cookie, $prefix;
$user = base64_decode($user);
$cookie = explode(":", $user);
$result = mysql_query("select pass from $prefix"._users." where
uname='$cookie[1]'");
list($pass)= mysql_fetch_row($result);
if ($cookie[2] == $pass && $pass != "") {
return $cookie;
} else {
unset($user);
unset($cookie);
}
}
I have determined that everything works up until the mysql_fetch_row
function. i did this by inserting
die($result) on the line prior to mysql_fetch_row.
The resulting output is this: Resource id #2
I have been able to run the query inside mysql, and went so far as to have
php die at the $cookie[1] and $cookie[2], just to verify that it was
looking at the right information.
Any ideas or suggestions as far as this is concerned would be a great
help.
Thank you,
-- Rex -- Edit bug report at: http://bugs.php.net/?id=13314&edit=1-- PHP Development Mailing List <http://www.php.net/> To unsubscribe, e-mail: php-dev-unsubscribe <email protected> For additional commands, e-mail: php-dev-help <email protected> To contact the list administrators, e-mail: php-list-admin <email protected>
- Next message: swm <email protected>: "[PHP-DEV] Bug #13314 Updated: Warning: Supplied argument is not a valid MySQL result resource"
- Previous message: Andi Gutmans: "Re: [PHP-DEV] Re: Bug #13304 Updated: string comparisons not working as expected"
- Next in thread: swm <email protected>: "[PHP-DEV] Bug #13314 Updated: Warning: Supplied argument is not a valid MySQL result resource"
- Reply: swm <email protected>: "[PHP-DEV] Bug #13314 Updated: Warning: Supplied argument is not a valid MySQL result resource"
- Reply: rex <email protected>: "[PHP-DEV] Bug #13314 Updated: Warning: Supplied argument is not a valid MySQL result resource"
- Reply: rex <email protected>: "[PHP-DEV] Bug #13314 Updated: Warning: Supplied argument is not a valid MySQL result resource"
- Reply: mfischer <email protected>: "[PHP-DEV] Bug #13314 Updated: Warning: Supplied argument is not a valid MySQL result resource"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

