Have a 'look' at the object that is getting returned.
Insert 'asdf($obj_name);' as shown below and also put this script in your code.
function asdf($object, $where=false)
// Used for debugging. Reason for odd name is easy to type but also easy to
find in code to get rid of
{
$type = gettype($o
Ok .. I figured it out now guys. Sorry for the hassle.
returning the object is fine, but if you don't assign another variable
with it after the function call it doesn't presist.
So what I did was (after the function declaration in the code):
if ($_GET['item']) $newitem = show_item($_GET['item']
Thanks for the answers so far guys ... the thing that puzzles me is
that the query definately works fine, because if I do this:
---
function show_item($item) {
$sublvl = $_GET['sub'];
$qry_item = query("select ITMLIST.*, GRPLIST.NAME AS SUBNAME from
ITMLIST, GRPLIST where ITMLIST.IT
I'm guessing your ibase_fetch_object($qry_result) call does not
successfully retrieve any data. It then returns false and your calling
script does nothing if false is returned.
At 09:32 PM 30/06/2004, you wrote:
Hi lads,
I'm just tinkering around in PHP again recently, I haven't done much
OO in
Ragnar wrote:
Hi lads,
I'm just tinkering around in PHP again recently, I haven't done much
OO in general, so I wasn't too surpised when some of the stuff I did
today didn't work.
Example:
(DB abstraction):
function data($qry_result){
if ($qry_result){
return ibase_fetch_object($qry_result);
}
Hi lads,
I'm just tinkering around in PHP again recently, I haven't done much
OO in general, so I wasn't too surpised when some of the stuff I did
today didn't work.
Example:
(DB abstraction):
function data($qry_result){
if ($qry_result){
return ibase_fetch_object($qry_result);
}
}
(I