Hi I am trying to edit the new transaction email of terawallet by using Woocommerce Email Customizer by drag and drop published by flycart. I am able to edit every static part of the email however I am not able to enter the dynamic content into the email such as total debited or credited amount to the wallet.
I am trying to add this by using their custom shortcode.
if(isset($attr[‘type’]) && $attr[‘type’] == ‘pre-order-link’)
{
printf( __( “Your pre-order is now available, but requires payment. %sPlease pay for your pre-order now.%s”, ‘wc-pre-orders’ ), ‘get_checkout_payment_url() . ‘”>’, ‘‘ );
}
This is the pattern of the code which needs to be entered into their custom.php file. The codes which I want to enter is
?>
<?php if ( $type == ‘credit’ ) { ?>
<p><?php _e( “Thank you for using your wallet.”, ‘woo-wallet’ ); ?> <?php echo wc_price( $amount, woo_wallet_wc_price_args($user->ID) ); ?> <?php _e( ‘has been credited to your wallet.’, ‘woo-wallet’ ); ?> <?php _e( ‘Current wallet balance is’, ‘woo-wallet’ ); ?> <?php echo woo_wallet()->wallet->get_wallet_balance( $user->ID ); ?></p>
<?php } ?>
<?php if ( $type == ‘debit’ ) { ?>
<p><?php _e( “Thank you for using your wallet.”, ‘woo-wallet’ ); ?> <?php echo wc_price( $amount, woo_wallet_wc_price_args($user->ID) ); ?> <?php _e( ‘has been debited from your wallet.’, ‘woo-wallet’ ); ?> <?php _e( ‘Current wallet balance is’, ‘woo-wallet’ ); ?> <?php echo woo_wallet()->wallet->get_wallet_balance( $user->ID ); ?></p>
<?php } ?>
<?php
I am not able to do this. Please guide me. I am not a coder so kindly keep your response simple or else just give me a code which I need to paste it there.
Thanks and Regards.