remove_fee() not work !
-
I used this add_fee() function to theme download_detalis.php widget by copy/pasting this sample code :
function pw_add_handling_fee() { // Add a $10 handling fee no matter what EDD()->fees->add_fee( '10', 'Handling Fee', 'handling_fee' ); } add_action( 'init', 'pw_add_handling_fee' ); //adding fee for test pw_add_handling_fee();
Then fee successfully added to cart page by title of
Handling Fee
But when i tried to remove fee that i’ve added for test by using remove_fee() with the code below nothing happend and fee didn’t removed !!!The code that i used for remove is the sample code :
function pw_remove_handling_fee() { EDD()->fees->remove_fee( 'handling_fee' ); } add_action( 'init', 'pw_remove_handling_fee', 9999 );
I didn’t change anything , Just used the sample code , As you see.
Now! i forced to change 10 to 0 temporary to adding 0 extra cost to user cart !! AAhhuughh
Please help me with this bug !
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘remove_fee() not work !’ is closed to new replies.