Skip to content

Instantly share code, notes, and snippets.

@kartikparmar
Created January 28, 2022 12:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kartikparmar/0beae2b25f8a241fde168687dd079aa2 to your computer and use it in GitHub Desktop.
Save kartikparmar/0beae2b25f8a241fde168687dd079aa2 to your computer and use it in GitHub Desktop.
Showing Full Payment information in the Pricing Box
<?php
function bkap_appending_additional_information_to_price( $display_price, $data ) {
if ( isset( $data['total_price_calculated'] ) ) {
$label = __( 'Full Payment: ', 'woocommerce-booking' );
$full_price = $label . wc_price( $data['total_price_calculated'] ) . '</br>';
$display_price = $full_price . $display_price;
}
return $display_price;
}
add_filter( 'bkap_appending_additional_information_to_price', 'bkap_appending_additional_information_to_price', 10, 2 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment