Problem with rateThis admin panel in 1.6.6 (SOLVED)

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
palaueb
New Member
New Member
Posts: 7
Joined: Thu Nov 12, 2009 10:54 am

Problem with rateThis admin panel in 1.6.6 (SOLVED)

Post by palaueb »

Hi, I got this error when I enter the admin panel for rateThis module:

[12-Nov-2009 11:46:58] PHP Fatal error: 
Call to a member function getContent() on a non-object in
/usr/home/xxxxxxxxxxxxxxx/web/modules/RateThis/function.ratingsTab.php on line 39

Well, the solution that works for me whas edit that file and edit this code:

Code: Select all

$hm = $gCms->GetHierarchyManager();
$node = $hm->getNodeById($row['pageID']);
$content =& $node->getContent();
if ($content != null) //Just in case
{
     $pageTitle=$content->Name();
}
for this one:

Code: Select all

$hm = $gCms->GetHierarchyManager();
$node = $hm->getNodeById($row['pageID']);
if($node != null){
$content =& $node->getContent();
if ($content != null) //Just in case
{
     $pageTitle=$content->Name();
}
}//node diff null
Hope it helps
scooper
Forum Members
Forum Members
Posts: 242
Joined: Fri Dec 09, 2005 12:36 pm

Re: Problem with rateThis admin panel in 1.6.6 (SOLVED)

Post by scooper »

Ah - had you deleted a page with ratings on or something?

Good find anyway, I'll add it into svn. Thanks for letting us know.

Just as a general point, there are a couple of newer Ratings modules in the forge as well, development on this one is er slow at best.

Cheers.

s.
palaueb
New Member
New Member
Posts: 7
Joined: Thu Nov 12, 2009 10:54 am

Re: Problem with rateThis admin panel in 1.6.6 (SOLVED)

Post by palaueb »

scooper, thanks for your reply.

I use this for it's simplicity, I just want to eval the page and got a list of votes, without any other content.

For me it's OK :)
thanks again!
ESBertrand
Forum Members
Forum Members
Posts: 21
Joined: Tue Feb 02, 2010 5:02 am

Re: Problem with rateThis admin panel in 1.6.6 (SOLVED)

Post by ESBertrand »

Just FYI, I ran into this same error when trying to access a private page when not logged on (using FrontEndUsers and the CustomContent module).  The error pointed to a nearly exact copy of the above function, but in /lib/misc.functions.php, so I made the same code fix and the problem no longer occurs.  However, at this moment the redirect isn't working (hoping that's something else....).

Erik
Post Reply

Return to “Modules/Add-Ons”