admin-menus
1 month ago
currencies
1 month ago
template-classes
1 month ago
translation-editor
1 month ago
class-wcml-ajax-setup.php
1 month ago
class-wcml-attributes.php
1 month ago
class-wcml-capabilities.php
1 month ago
class-wcml-cart-removed-items-widget.php
1 year ago
class-wcml-cart-switch-lang-functions.php
1 month ago
class-wcml-cart-sync-warnings.php
1 month ago
class-wcml-cart.php
1 month ago
class-wcml-comments.php
1 month ago
class-wcml-compatibility.php
1 month ago
class-wcml-coupons.php
1 month ago
class-wcml-dependencies.php
1 month ago
class-wcml-emails.php
1 month ago
class-wcml-endpoints.php
1 month ago
class-wcml-install.php
1 month ago
class-wcml-languages-upgrader.php
1 month ago
class-wcml-locale.php
1 month ago
class-wcml-orders.php
1 month ago
class-wcml-products-screen-options.php
1 month ago
class-wcml-products.php
1 month ago
class-wcml-reports.php
1 month ago
class-wcml-requests.php
1 month ago
class-wcml-resources.php
1 month ago
class-wcml-store-pages.php
1 month ago
class-wcml-terms.php
1 month ago
class-wcml-tp-support.php
1 month ago
class-wcml-troubleshooting.php
1 month ago
class-wcml-upgrade.php
1 month ago
class-wcml-url-translation.php
1 month ago
class-wcml-wc-gateways.php
1 month ago
class-wcml-wc-shipping.php
1 month ago
class-wcml-wc-strings.php
1 month ago
class-wcml-widgets.php
1 month ago
constants.php
1 month ago
functions-pure.php
1 month ago
functions.php
1 month ago
installer-loader.php
1 month ago
missing-php-functions.php
1 month ago
wcml-core-functions.php
1 month ago
wcml-switch-lang-request.php
1 month ago
class-wcml-cart-removed-items-widget.php
28 lines
| 1 | <?php |
| 2 | |
| 3 | class WCML_Cart_Removed_Items_Widget extends WP_Widget { |
| 4 | |
| 5 | public function __construct() { |
| 6 | |
| 7 | $widget_opt = [ |
| 8 | 'description' => __( 'Shows a list of the products that existed in the cart before the cart is reset on the front end after switching the language or the currency. It will be hidden when there are no products to show.', 'woocommerce-multilingual' ), |
| 9 | ]; |
| 10 | |
| 11 | parent::__construct( |
| 12 | 'wcml_cart_deleted_items', |
| 13 | __( 'Products before cart reset', 'woocommerce-multilingual' ), |
| 14 | $widget_opt |
| 15 | ); |
| 16 | |
| 17 | } |
| 18 | |
| 19 | public function widget( $args, $instance ) { |
| 20 | |
| 21 | echo $args[ 'before_widget' ]; |
| 22 | |
| 23 | do_action( 'wcml_removed_cart_items' ); |
| 24 | |
| 25 | echo $args[ 'after_widget' ]; |
| 26 | } |
| 27 | |
| 28 | } |