Last active
September 13, 2024 22:41
-
-
Save kloon/4541017 to your computer and use it in GitHub Desktop.
Revisions
-
kloon renamed this gist
Jan 15, 2013 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
kloon revised this gist
Jan 15, 2013 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,7 +1,7 @@ // check for clear-cart get param to clear the cart, append ?clear-cart to any site url to trigger this add_action( 'init', 'woocommerce_clear_cart_url' ); function woocommerce_clear_cart_url() { if ( isset( $_GET['clear-cart'] ) ) { global $woocommerce; $woocommerce->cart->empty_cart(); } -
kloon created this gist
Jan 15, 2013 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,8 @@ // check for clear-cart get param to clear the cart, append ?clear-cart to any site url to trigger this add_action( 'init', 'woocommerce_clear_cart_url' ); function woocommerce_clear_cart_url() { 21if ( isset( $_GET['clear-cart'] ) ) { global $woocommerce; $woocommerce->cart->empty_cart(); } }