Posted by Akhenaten on 05/18/07 14:18
For whatever reason I can't get my return value to pass outside of the
function I've created. I've tested all the responses within the
function so I know the data is there and the sql query is valid. Am I
missing something to get it passed outside the function?
******************************
function respond_check($qid,$username)
{
include "db.inc.php";
$postchk2 = mysql_query("SELECT username FROM `answers` , `users`
WHERE `qid` = $qid AND `a_uid` = `userid` LIMIT 0, 30",$db);
while ($userx=mysql_fetch_array($postchk2))
{
if (in_array($username,$userx)) {
$freturn = 7;
return $freturn;
}
}
}
******************************
[Back to original message]
|