Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi svovaf,

    Well, what I did was:

    – Using the Plugins->Editor in WordPress I loaded the rating-widget.php file

    – Then, I modified the following code:
    RW.init("<?php echo WP_RW__USER_KEY; ?>");

    And changed it for this:

    RW.init("<?php echo WP_RW__USER_KEY; ?>",{
    beforeRate: function(vote, rating){
    if (!is_logged_in()){
    return false;
    }else{
    return get_user_id();
    }
    }
    });
    RW.render();

    Again, the only way I could get the plugin to work again was by uninstalling it and then re-installing it.

    One thing I did though was to check the values on the database and although the values were correctly set, the plugin always used the default values and didn’t save any changes.

    I tried to implement the “Forcing log-in before rating” code change and it didn’t work. I was able to rate without being logged in.

    Then I noticed that the widget stopped saving any changes.
    So I had to uninstall it and re-install it to get it to work.

Viewing 2 replies - 1 through 2 (of 2 total)