Rate Plugin v0.1

Release Notes

A simple rate plugin. Just install the plugin and add to the object view (blog view for example):

elgg_view('rate/rate', array('entity'=> $vars['entity']));

 

Enjoy it!

And report feedback please :)

 

Screenshots:

image

image

 

  • I've added this to my TidyPics.

    The code

     

    elgg_view('rate/rate', array('entity'=> $vars['entity']));

    goes in /mod/tidypics/views/default/object/image.php just under the tidypics individual image display section. I put it under $viewer = get_loggedin_user();
    then i re-uploaded that tidypics page, enabled this plugin, and it works great.
    i also added gfroese's code
    $viewer = get_loggedin_user();
            
            //don't let the owner of the entity vote on stuff they own
            if($viewer->guid == $entity->owner_guid) {
                return false;
            }
    in /mod/rate/start.php just under $viewer = get_loggedin_user(); and now you can only rate the photo once, and you can't rate your own. if you view your own photo, it shows the ratings stars, but not the selection or the buttons. or, if you view a photo that you've rated already, it does the same thing. so i got it to work very nicely.
    and i'm running 1.7.5
    Alan

     

     

  • i have worked, but how can I add rate function or show rating to river dashboard?

Stats

  • Category: Uncategorized
  • License: GNU General Public License (GPL) version 2
  • Updated: 2014-11-17
  • Downloads: 4930
  • Recommendations: 1

Other Projects

View Miguel Montes's plugins