1
dleewo
Error display news item (Xoops 2.2.3a and news 1.4) - SOLVED
  • 2005/11/1 13:40

  • dleewo

  • Just popping in

  • Posts: 12

  • Since: 2004/9/16


When I try to display a new items by clicking on the title, I get the following error:

Fatal error: Call to a member function on a non-object in /home/dleewo/public_html/test.leewo.net/xoops/modules/news/include/functions.php on line 319

This only happens if I'm logged in as a user. If I'm not logged it, it displays fine.

Also, whether logged in or not, the items is displayed OK on the main news page. I only see the problem if I click on the title.

I pulled up the code referred to. Here is line 319:

$xoopsConfigMetaFooter =& $config_handler->getConfigsByCat(XOOPS_CONF_METAFOOTER);


Does anyone have any suggestions?

2
dleewo
Re: Error display news item (Xoops 2.2.3a and news 1.4)
  • 2005/11/1 21:08

  • dleewo

  • Just popping in

  • Posts: 12

  • Since: 2004/9/16


OK...I think I've found and fixed the problem. In the file functions.php at line 319, there should be a call as follows:

$config_handler =& xoops_gethandler('config');

I've added that so the code now looks like this:

if(count($tmp)>0) {
return implode(',',$tmp);
} else {
// New line below
$config_handler =& xoops_gethandler('config');
$xoopsConfigMetaFooter =& $config_handler->getConfigsByCat(XOOPS_CONF_METAFOOTER);
return $xoopsConfigMetaFooter['meta_keywords'];
}

This now works correctly. I still don't know why I only go through this branch when I'm logged in as a user.

Login

Who's Online

196 user(s) are online (123 user(s) are browsing Support Forums)


Members: 0


Guests: 196


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits