• Resolved tin_soldier

    (@tin_soldier)


    Hi, just wondering if there’s a method to make the average rating in the summary show at 2 decimal places ie; 4.85.

    I’m using v5 beta.

    Thanks

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

    (@geminilabs)

    You will need to update to the latest development version as the parameter order of the site-reviews/rating/average filter hook has changed.

    Once you have updated, you can do this:

    add_filter('site-reviews/rating/average', function ($roundedAverage, $average) {
        return round($average, 2); // change to 3 for three decimals
    }, 10, 2);
    Thread Starter tin_soldier

    (@tin_soldier)

    Brilliant. Thanks!

    Amazing support

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Summary average decimal’ is closed to new replies.