How to disable lightbox popup for “add a review” only?

By default in woocommerce when a user wants to add a review of a product, they click ‘add a review’ and this opens up a pop-up lightbox.
I want to disable this part and just display the review form.
Anybody has any ideas?

Related posts

Leave a Reply

1 comment

  1. Here’s a hack you can use.

    Update: As Andrew Bartel mentioned below. It’s best to copy the template files into your theme so that they override the default woo commerce template files.

    In your woocommerce plugin folder, look for a file called product-reviews.php

    woocommerce/templates/single-product-reviews.php
    

    Look for a line that says

    <div id="review_form_wrapper">
    

    Either remove the class review_form_wrapper, or add a 1 in front of it. That will make the hidden form visible.

    Next you will want to remove the other buttons that says ADD REVIEW (triggers lightbox), because you will already have the SUBMIT REVIEW button at the end.

    You will want to modify these lines to your needs:

    <a href="#review_form" class="inline show_review_form">submit yours</a>
    
    <a href="#review_form" class="inline show_review_form button" title="' . __( 'Add Your Review', 'woocommerce' ) . '">' . __( 'Add Review', 'woocommerce' ) . '</a>
    

    You could either remove the lines above, or you could just add a display:none to each paragraph element to hide the whole thing

     style="display:none"