2

I am trying to add a line of text on the checkout page of the store that will go immediately after shipping row. I added the following to my child theme functions.php file:

 add_action( 'woocommerce_review_order_after_shipping', 'action_woocommerce_review_order_after_shipping');

function action_woocommerce_review_order_after_shipping( ) {
    echo = "<p>Text Goes Here</p>";
};

For some reason it leads to a 500 error. Any idea what I am doing wrong?

1 Answer 1

5

Remove the = sign after your echo statement...

echo = "<p>Text Goes Here</p>";

...becomes

echo "<p>Text Goes Here</p>";

Final

 add_action( 'woocommerce_review_order_after_shipping', 'action_woocommerce_review_order_after_shipping');

function action_woocommerce_review_order_after_shipping( ) {
    echo "<p>Text Goes Here</p>";
}
2
  • wow...I have been looking at this for way too long. thanks! Mar 3, 2016 at 23:49
  • 3
    No problem :) ...don't forget to mark the question correct to close it out. All the best.
    – Adam
    Mar 4, 2016 at 2:29

Your Answer

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

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