shshanker
9/21/2015 - 9:54 AM

Remove bank details from thank you page

Remove bank details from thank you page

<?php
add_action('template_redirect', function(){
	foreach ($GLOBALS['woocommerce']->payment_gateways->payment_gateways as $key => $gateway_obj){
		if( 'WC_Gateway_BACS' == get_class( $gateway_obj ) ){	
    	remove_action( 'woocommerce_thankyou_bacs', array( $gateway_obj, 'thankyou_page' ) );
	}
	}
} );

?>