• Resolved ti00it

    (@ti00it)


    I want to first appreciate the awesomeness of this plugin. It is by far one of the best WP review plugins out there.

    I was wondering if there is a way to do this, or to request this feature:
    In the shortcode to display reviews, I would like to add two params:
    orderby=random
    max_num_pages=<some int>

    Is there a way I can do this already?

Viewing 1 replies (of 1 total)
  • Plugin Author Gemini Labs

    (@geminilabs)

    You can use the display option on the shortcode (along with the pagination option) to change the number of reviews that are displayed.

    However, random sorting doesn’t really work on most sites due to caching which is why Site Reviews does not provide this option.

    If you want to do this anyway, here is a custom shortcode snippet that may help you get started: https://pastebin.com/naUae8zB

    A more advanced solution is to write some javascript which uses ajax to get the reviews on page load, using the glsr_get_reviews in the PHP callback function to order reviews randomly (using the orderby option in the function).

    • This reply was modified 3 years, 6 months ago by Gemini Labs.
Viewing 1 replies (of 1 total)
  • The topic ‘Enhance review display shortcode’ is closed to new replies.