Acers
05-29-2005, 01:56 AM
was trying to get some page into the who's online system. was doing pattern recognition. the code is like :
elseif (preg_match("/topic\/(\d*)-\d*/", $userinfo['location'], $tester1))
{
$titlethrd = $DB_site->query("
SELECT title
FROM " . TABLE_PREFIX . "thread
WHERE threadid = " . intval($tester1[1]) . "
");
$userinfo['where'] = "<a href=\"search/topic/$tempo-1.html\"\">$titlethrd[title]</a>";
}
idea being that if there is a match then in $tester1[1] i will have the thread id(which i do have , i have checked via echo. Now on the line
$titlethrd = $DB_site->query("
i am getting
Fatal error: Call to a member function on a non-object
what does that mean?
elseif (preg_match("/topic\/(\d*)-\d*/", $userinfo['location'], $tester1))
{
$titlethrd = $DB_site->query("
SELECT title
FROM " . TABLE_PREFIX . "thread
WHERE threadid = " . intval($tester1[1]) . "
");
$userinfo['where'] = "<a href=\"search/topic/$tempo-1.html\"\">$titlethrd[title]</a>";
}
idea being that if there is a match then in $tester1[1] i will have the thread id(which i do have , i have checked via echo. Now on the line
$titlethrd = $DB_site->query("
i am getting
Fatal error: Call to a member function on a non-object
what does that mean?