RE: [PHP] Bizarre SQl, if issue....

From: Date: Tue, 29 Jul 2003 20:42:50 +0000
Subject: RE: [PHP] Bizarre SQl, if issue....
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-157427@lists.php.net to get a copy of this message
Hi Mike, List Where is the $place variable coming from that you use in your query's where clause? I hope it is not being POST'ed or GET'ed (sic), cause then you might have the dreaded old register_globals issue. Humour me, echo your sql string in your code and see if it actually has something in the $place. -----Original Message----- From: Mike At Spy [mailto:spycobalt@spyproductions.com] Sent: Tuesday, July 29, 2003 9:25 PM To: Jay Blanchard; Mike At Spy; php-general@lists.php.net Subject: RE: [PHP] Bizarre SQl, if issue.... > [snip] > > $person = mysql_query("The Query"); > > $thecount = mysql_num_rows($person); > > echo "$thecount \n"; > > > > And tell us what $thecount is... > > Returns 0 (zero). > [/snip] > > Then > if($thecount == 0){ > $whatever = 1; > } else { > $whatever = 4; > } > > $whatever should be 1 But that is my point - and I think we are going in circles now. It just doesn't do that. It returns 4 (as per your example). :\ -Mike -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

« previous php.general (#157427) next »