Notice: Trying to get property of non-object

  • fernando
    Inactive member
  • Topic Author
  • New Member
  • New Member
More
13 years 8 months ago #6443 by fernando
Hi, I just installed the template and opened the site and i´m receiving this message

Notice: Trying to get property of non-object in F:\wamp\www\pibarraial\components\com_content\router.php on line 49


apache 2.2.11
php 5.2.9
mysql 5.1.36

Please Log in to join the conversation.

More
13 years 8 months ago #6447 by ivan.milic
Turn off debugging in joomla.

Please Log in to join the conversation.

  • fernando
    Inactive member
  • Topic Author
  • New Member
  • New Member
More
13 years 8 months ago #6448 by fernando
Debug option was already off.
I just install the template and acess the site.
the problem continue.
thanks for help

Please Log in to join the conversation.

More
13 years 8 months ago #6462 by ivan.milic
Hi,

You can then try to clean that message by changing code. Apparently this should do the trick:
Open router.php and around the 49th line you will see this:

if ($menuItem->query == $query && isset($query) && $menuItem->query == intval($query)) {
unset($query);

if (isset($query)) {
unset($query);
}

unset($query);

return $segments;
}

surround hat with "if" that will check $menuItem variable:

if(isset($menuItem)){
if ($menuItem->query == $query && isset($query) && $menuItem->query == intval($query)) {
unset($query);

if (isset($query)) {
unset($query);
}

unset($query);

return $segments;
}

}

Please Log in to join the conversation.

Time to create page: 0.222 seconds
Powered by Kunena Forum