Support » Plugin: Rating-Widget: Star Review System » My theme doesn't use the_excerpt()

  • Resolved Wizd3m



    I could really use some help with this (awesome) plugin on my website.

    Basically, all I want is for the ratings to display on my front page post excerpts. Sadly, my theme (Gamepress) uses gamepress_excerpt for PHP code, rather than the apparently needed the_excerpt(). As a test, I renamed the prior to the latter in my theme php file responsible for excerpts, and the ratings appeared. Sadly, the excerpt itself became all out of whack, so I changed everything back to default.

    Is there anything that can be done to keep my current excerpt layouts AND have the ratings appear?

    Furthermore, my actual desire is to have the ratings appear in the excerpt headings (where the title of post is) rather than in the actual content box. I’ve managed to do that as well by simply adding <?php rw_the_post_rating($post->ID); ?> into that same theme php file responsible for excerpts. This way, I keep my excerpt alignment AND get the rating exactly where I want. BUT, now the ratings show for every single post on the front page, even those that shouldn’t have it.

    I feel like I’m so close to finding a solution, could someone please suggest something?

    Thank you very much for taking the time to read all of this.


Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author RatingWidget


    Seems like you are almost 🙂 When you say “now the ratings show for every single post on the front page”, what filtering do you use to prevent from ratings to show on specific posts? Is it by category? By post id?

    Thank you for answering!

    I have “all categories” selected, and have added a few exceptions based on ID. So yea, I’m filtering by post ID.

    Plugin Author RatingWidget


    Apologies for the late response, try to do the following:

    1. Open the main plugin’s file, rating-widget.php, and make the method rw_validate_visibility public.
    2. Now, instead of the code you’ve previously added. Try to use this:
          if (ratingwidget()->rw_validate_visibility($post->ID, 'blog-post'))

    Let me know if it worked.

    No worries, thank you for getting back to me.

    As far as making the method rw_validate_visibility public, I’m sadly unsure of how that is done. I’m not very knowledgeable when it comes to PHP and mostly rely on trial and error to learn. Could you please explain?

    Nevertheless, I still added the code you provided, just as I did before, and it worked! Posts where ratings are unneeded are now being skipped! The rest show on the front blog page as desired, take a look:

    Should I still worry about rw_validate_visibility?

    Plugin Author RatingWidget


    Awesome! I’m happy it worked. And it looks great on your blog. No need to worry about rw_validate_visibility.

    Btw. I would really appreciate if you could spend 60 sec rating the plugin on WP to help us spread the word (don’t forget to click the Post button to submit the rating):

    Of course, and done 🙂

    Thank you for all your help, and your awesome plugin. I’ve been wanting to have the stars appear on the front page for some time, and am soo happy to finally have it working and looking the way I was hoping.

    Thanks for you patience.


    Plugin Author Vova Feldman


    Thanks 🙂

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘My theme doesn't use the_excerpt()’ is closed to new replies.