Skip to content

Instantly share code, notes, and snippets.

@jfarsen
Created August 9, 2017 01:39
Show Gist options
  • Save jfarsen/45491d5a588e89e0d2ddad033a2146f3 to your computer and use it in GitHub Desktop.
Save jfarsen/45491d5a588e89e0d2ddad033a2146f3 to your computer and use it in GitHub Desktop.
Add a custom notice before the payment on the WooCommerce checkout
<?php
/**
* Add add a notice before the payment form
* Source : https://github.com/woothemes/woocommerce/blob/master/templates/checkout/review-order.php
*/
add_action( 'woocommerce_review_order_before_payment', 'arscons_before_paying_notice' );
function arscons_before_paying_notice() {
wc_print_notice( __( 'some custom message', 'woocommerce' ), 'notice' );
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment