• Resolved BB1975

    (@bb1975)


    Hi Paul,

    First of all, thanks for this awesome plugin…

    I’m having a schema issue that I was hoping you could help me with. I’m using the Schema Pro plugin (wpschema.com) to handle the schema for my website and I’m mapping the review rating and review count to glsr average and glsr count. However, it doesn’t appear that Site Reviews is working properly as I’m getting an aggregate rating error when I check the pages in Google’s structured data tool:

    “One of ratingCount or reviewCount must be provided.”

    Any ideas?

    Thanks in advance, Paul. I really appreciate you!

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

    (@geminilabs)

    What is the URL?

    Thread Starter BB1975

    (@bb1975)

    Hi Paul, thank you for your quick reply. How can I send it to you privately?

    Plugin Author Gemini Labs

    (@geminilabs)

    Follow the instructions on the “Contact Support” section on the Help page.

    Plugin Author Gemini Labs

    (@geminilabs)

    The problem was due to incorrect usage of the _glsr_count meta_key which contrary to how the meta_key sounds, does not store the number value of the total assigned reviews but rather a rating array of the assigned reviews.

    To solve this, you will need to contact the Schema Pro developer to see if they provide a filter hook where you can use the provided glsr_get_rating function to get the rating counts. For example:

    $ratingInfo = apply_filters('glsr_get_rating', null, [
        'assigned_to' => 'post_id',
    ]);
    $ratingCount = !empty($ratingInfo) ? $ratingInfo->reviews : 0;
    
    
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Schema issue (glsr average and glsr count)’ is closed to new replies.