Hi There,
We have improved invoice details sending via email notification. Now it will display bank instructions and bank details like a/c no, name etc on invoice view page & in email too.
The instruction and bank details will be displayed only on pending payment invoices.
Please check screenshots in next reply.
In case you want any custom text on invoice email, then you following code snippet.
function _wpi_custom_invoice_email_before_details( $invoice, $email_type = '', $sent_to_admin = false ) {
if ( !empty( $invoice ) && $invoice->gateway == 'bank_transfer' && $invoice->status == 'wpi-pending' ) {
// YOUR HTML CODE
?>
<?php
}
}
add_action( 'wpinv_email_invoice_details', '_wpi_custom_invoice_email_before_details', 9, 3 );
You can change “bank_transfer” to “cod”, “paypal” etc for other gateways.
Thanks,
Kiran