Change Place Order Button Text to include Order Total in WooCommerce

Change place order button text to include order total if using WooCommerce on your child site.

Snippet Type

Execute on Child Sites


add_filter('woocommerce_order_button_text', 'place_order_button_with_order_total');
function place_order_button_with_order_total(){
    return sprintf( '%s %s', __( 'Place Order & Pay', 'custom-order-button' ), strip_tags( WC()->cart->get_total() ) );
1 Like

Example of the change.
Place Order Button include order total

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.