Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function woo_add_cart_fee() {
- global $woocommerce;
- $admin_fees = get_option( 'admin_fees', 10 );
- $stamp_duty = get_option( 'stamp_duty', 10 );
- $refundable_deposit = get_option( 'refundable_deposit', 10 );
- $woocommerce->cart->add_fee( __('Admin Fees', 'woocommerce'), $admin_fees );
- $woocommerce->cart->add_fee( __('Stamp Duty', 'woocommerce'), $stamp_duty );
- $woocommerce->cart->add_fee( __('Refundable Deposit', 'woocommerce'), $refundable_deposit );
- }
- add_action( 'woocommerce_cart_calculate_fees', 'woo_add_cart_fee' );
- function woo_add_cart_fee() {
- global $woocommerce;
- $admin_fees = get_option( 'admin_fees', 10 );
- $stamp_duty = get_option( 'stamp_duty', 10 );
- $refundable_deposit = get_option( 'refundable_deposit', 10 );
- $woocommerce->cart->add_fee( __('Admin Fees', 'woocommerce'), $admin_fees, TRUE, '');
- $woocommerce->cart->add_fee( __('Stamp Duty', 'woocommerce'), $stamp_duty, TRUE, '' );
- $woocommerce->cart->add_fee( __('Refundable Deposit', 'woocommerce'), $refundable_deposit, TRUE, '' );
- }
- add_action( 'woocommerce_cart_calculate_fees', 'woo_add_cart_fee' );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement