• Resolved stylise

    (@stylise)


    Hello. How can I enable reviews for our entire product catalog so that we can take full advantage of the WooCommerce integration? We have too many products to do this manually.

    The setting I’m referring to is under Product > Product data > Site Reviews > Enable reviews

    Thanks in advance.

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

    (@geminilabs)

    Unfortunately, WooCommerce does not allow you to bulk edit products without using one of their WooCommerce addons.

    Fortunately, you can do this with a code snippet:

    1. Install the Code Snippets plugin
    2. Add the code snippet below and set the code snippet to run one time only.
    3. Execute the snippet.

    After you have done this you can delete the code snippet (and uninstall the Code Snippets plugin if you no longer need it).

    add_action('admin_init', function () {
    global $wpdb;
    $wpdb->update("UPDATE {$wpdb->posts} SET comment_status = 'open' WHERE post_type = 'product' AND post_status = 'publish'");
    });
    Thread Starter stylise

    (@stylise)

    @geminilabs Thank you for the detailed suggestion, but unfortunately that doesn’t seem to have worked.

    Plugin Author Gemini Labs

    (@geminilabs)

    Strange, I tested this and it works for me.

    1. Are reviews enabled on the WooCommerce > Settings > Products page?
    2. Is the WooCommerce integration enabled in the Site Reviews settings?
    3. How did you create and run the snippet?
    4. Did you check a Product after running it to see if reviews are enabled on that specific product (Product data > Site Reviews > Enable reviews)?
    Thread Starter stylise

    (@stylise)

    @geminilabs First off, I realize that this request is essentially out of the scope of Site Reviews, especially considering this is the free support forums, so I appreciate your willingness to help.

    1. Yes
    2. Yes
    3. Using the Code Snippets plugin and the instructions provided
    4. Yes, the box remains unchecked
    Plugin Author Gemini Labs

    (@geminilabs)

    Ah, sorry: I tested the SQL query but not the code snippet.

    Try this code snippet instead:

    add_action('init', function () {
    global $wpdb;
    $wpdb->query("UPDATE {$wpdb->posts} SET comment_status = 'open' WHERE post_type = 'product' AND post_status = 'publish'");
    });

    And instead of running once:

    1. Change it to “Run snippet everywhere”
    2. Activate the snippet
    3. Refresh the page.
    4. Then deactivate it again after the page has refreshed.
    • This reply was modified 1 week, 3 days ago by Gemini Labs.
    Thread Starter stylise

    (@stylise)

    That did the trick, thanks a lot! I’ll be leaving a plugin review soon.

Viewing 6 replies - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.