On Tuesday 31 December 2002 20:48, Martin S wrote:
> This is the function which should return e.g. "printers" for $lookuptable.
> But doesn't.
>
> function setCurrentDevGroup($devID)
> {
> global $adb;
> $query = "SELECT dev_group FROM tracking WHERE (computer =
> $devID)"; $sth = $adb->prepare($query);
> if($sth)
> {
> $res = $sth->execute();
> $resulttable = $sth->fetchrow_hash();
> $lookuptable = $resulttable["dev_group"];
> // DEBUG
> echo $lookuptable; // this give the correct value
So here $lookuptable contains the correct value (eg "printers") ??
> }
> return $lookuptable;
> }
But something like:
echo setCurrentDevGroup($devID);
gives the wrong/no value? If so, could you show how you are using this
function in your code?
--
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *
/*
The whole world is a tuxedo and you are a pair of brown shoes.
-- George Gobel
*/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php