• Resolved McNitefly

    (@mcnitefly)


    Hi there!
    I use the ratings plugin on all posts – works great.

    Now I changed my frontpage / homepage to show the latest posts. ( so home shows https://www.sitename.com/blog )

    I would like to put a shortcode into a sidebar widget (of a sidebar that is only shown on frontpage). Is it possible to get the ratings to be counted for the frontpage?(www.sitename.com) Also regarding the rich snippets?

    Currently, when I insert the shortcode into the sidebar, it shows me the ratings of the post that is currently on top.

    Thanks,
    McNitefly

    https://www.ads-software.com/plugins/wp-postratings/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Lester Chan

    (@gamerz)

    Unless you know the ID of the post when you are in sidebar. You can use [ratings id=”123″] where 123 is the post ID otherwise it can’t be done as the ratings has to be within the WordPress loop. And for most theme, the sidebar is not within the loop.

    Thread Starter McNitefly

    (@mcnitefly)

    Thank you very much – that perfectly did the job!

    Since the blog page has its unique ID, I could simply use your shortcode and place it in the sidebar. And since in this case my wish was to have a “How do you like my website”-rating (and not a “how do you like this post, which I have on the individual articles”, this was exactly what I wanted.

    And I used the goog erich snipped tool – it does realize the rating correctly as related to my frontpage, like I wanted it. (To reach that, I had to put the shortcode again behind the posts list. It did not realize it when it was just in the sidebar – but that’s OK.)

    Thanks for your very fast help!

    Cheers,
    McNitefly

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Ratings on blog frontpage’ is closed to new replies.