Recent Topics

Star Rating Plugin - Top Rated not displaying in sidebar

Started by on May 27, 2007 – Contents updated: May 27, 2007

May 27, 2007 03:57    

I'm using version 1.9.3. I installed the Star Rating plugin and it works fine except that the top rated posts are not being added to the sidebar.

I added this code:

PHP

<?php $Plugins->call_by_code'starrating'array('display' => 'toprated''limit' => 5'minvote' => ) ); ?>

to the sidebar section of my skin's _main.php file. If I view the HTML code being generated I see:

Code

<div class="bSideItem"><h3>Top Rated</h3><ol></ol>
</div>

It looks like it isn't able to grab any items to popluate the ordered list:

Code

<ol></ol>

I'm trying to figure out what I'm doing wrong. Can someone point my in the right direction?

May 29, 2007 14:35

It won't show anything until you have enough ratings. If you don't have any post with at least one rating, then nothing will show up in that list. If that's not the problem, then could you give a link to your site and also mention your version of php and mysql?

May 29, 2007 18:29

Thanks for your response. What I realized after a while was that the mySQL query in _starrating.plugin.php included the category id in the WHERE clause. So the query was returning different results on different blogs. I was able to modify the query and return the top rated posts on all blogs (which is what I wanted). This is working great now.

I have run into another issue that you might be able to help me with. For some reason, Star Rating is no longer appearing under the list of Text Renderers on the Write tab in the back office when posts are composed. I have the 'Apply rendering' setting set to 'Opt-out' at the moment.

Do you think that uninstalling and then reinstalling the plugin would correct this?

Thanks again for your help.

May 29, 2007 18:38

Hmm, that's a strange problem. First try various values in the plugin settings like opt-in, always, etc, just to see if that knocks some sense into the plugin. If not, try reinstalling, which will erase all of the votes so far.


Form is loading...

powered by b2evolution – This forum is powered by b2evolution CMS, a complete engine for your website.