• Resolved Henk.Jan

    (@henkjan-1)


    I created categories and subcategories
    On a page you can rate to a subcategory I created and you can show the rating for this page
    But on multiple pages, belonging to a main category it doesn’t show up. Even at the category page there are no ratings visible in the main category, they are visible in the subcategories
    So what’s the use of creating main categories with subcategories

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Plugin Contributor Paul

    (@pryley)

    Categories in Site Reviews are only hierarchical because the very first version of Site Reviews registered the taxonomy as hierarchical (allowing parent categories and children categories) so it was left enabled so as not to break any custom integrations users may have done.

    However, due to the way Site Reviews manages review assignments (in custom pivot database tables), it does not treat its categories as hierarchical.

    In Site Reviews, if the thing you want to assign reviews to has a permalink (i.e. page, post, product, etc.), then you should assign reviews to that. If the thing you want to assign reviews to does not have a permalink, then you should assign reviews to categories instead.

    If there is a reason that you are assigning reviews to categories instead of assigning reviews directly to the bird pages, then I can provide you a PHP code snippet which will do what you want. However, it will add a tiny bit of overhead to the Site Reviews SQL queries.

    Here is the code snippet: https://pastebin.com/ACmsDsC3

    Bonus note: You may want to disable the infinite loading on your website because it prevents people from accessing the review form.

Viewing 1 replies (of 1 total)

You must be logged in to reply to this topic.