0

this is possible in woocommerce order complete generated mail...? i m Adding a review button in order complete generated mail for review about product ..it means after checkout process then send to also email to customer to all detail about billing and in this email i m adding also a custom review button in last.. if customer click to this button they directly go to our product page and give review to his product or all other product....but i don't know where i go and add to this button and all this function ..so please help me to add this custom button

i m trying so hard but not add this button .....if this is possible so please help me to put this custom review button in woocommerce order complete generated mail

1 Answer 1

0

You can overwrite woocommerce templates placing them in your theme. To overwrite e.g. email-order-details.php template, place it in yourtheme/woocommerce/email/email-order-details.php path.

You can also add action to add your custom review button.

function wpse_287685_woocommerce_email_after_order_table($order, $sent_to_admin, $plain_text, $email) {
    ?>
        <a href="#">Add review</a>
    <?php
}

add_action( 'woocommerce_email_after_order_table', 'wpse_287685_woocommerce_email_after_order_table', 10, 4 );
3
  • You have to place it in your theme files like functions.php not woocommerce files.
    – kierzniak
    Dec 4, 2017 at 14:08
  • What you mean by "others"? Do you want to add "Add review" button in some different places?
    – kierzniak
    Dec 4, 2017 at 14:18
  • Yes, you have to add only this part of code to your functions.php to add <a href="#">Add review</a> button.
    – kierzniak
    Dec 4, 2017 at 14:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.