-
-
Save kurtschlatzer/ebaf35cd3e5c033c7cc30cf83fbb9006 to your computer and use it in GitHub Desktop.
Revisions
-
WebEndevSnippets revised this gist
Jun 4, 2013 . 1 changed file with 1 addition and 0 deletions.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 @@ <input type="submit" class="button" name="clear-cart" value="<?php _e('Empty Cart', 'woocommerce'); ?>" /> -
WebEndevSnippets created this gist
Jun 4, 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,10 @@ /** * Clear Cart for WooCommerce */ add_action( 'init', 'we_woocommerce_clear_cart_url' ); function we_woocommerce_clear_cart_url() { global $woocommerce; if( isset($_REQUEST['clear-cart']) ) { $woocommerce->cart->empty_cart(); } }