get_id(); $product_id = intval(isset( $productid ) ? $productid : 0 ); } $is_button = ! isset( $button_or_link ) || ! $button_or_link ? get_option( 'yith_woocompare_is_button' ) : $button_or_link; if ( ! isset( $button_text ) || $button_text == 'default' ) { $button_text = get_option( 'yith_woocompare_button_text', esc_html__( 'Compare', 'buzzstore' ) ); yit_wpml_register_string( 'Plugins', 'plugin_yit_compare_button_text', $button_text ); $button_text = yit_wpml_string_translate( 'Plugins', 'plugin_yit_compare_button_text', $button_text ); } printf( '
%4$s
', 'javascript:void(0)', 'compare link-compare' . ( $is_button == 'button' ? ' button' : '' ), intval( $product_id ), esc_attr( $button_text ) ); } remove_action( 'woocommerce_after_shop_loop_item', array( 'YITH_Woocompare_Frontend', 'add_compare_link' ), 20 ); } /** * Product Wishlist Button Function */ if (defined( 'YITH_WCWL' )) { function buzzstore_wishlist_products() { global $product; $url = add_query_arg( 'add_to_wishlist', $product->get_id() ); $id = $product->get_id(); $wishlist_url = YITH_WCWL()->get_wishlist_url(); ?>
loading
get_wishlist_url(); ?>
cart->get_cart_contents_count(), 'buzzstore' ), WC()->cart->get_cart_contents_count() ) ); ?> cart->get_cart_subtotal() ); ?> '', 'orderby' => 'name', 'order' => 'ASC', 'hide_empty' => true, ); $product_categories = get_terms( 'product_cat', $args ); $categories_show = ''; $check = ''; if(is_search()){ if(isset($_GET['term']) && $_GET['term']!=''){ $check = sanitize_text_field( wp_unslash( $_GET['term'] ) ); } } $checked = ''; foreach($product_categories as $category){ if(isset( $category->slug )){ if(trim($category->slug) == trim($check)){ $checked = 'selected="selected"'; } $categories_show .= ''; $checked = ''; } } $form = '
'; echo $form; } } /** * Load buzzstore woocommerce Action and Filter. */ function buzzstore_woocommerce_breadcrumb(){ do_action( 'breadcrumb-woocommerce' ); } add_action( 'woocommerce_before_main_content','buzzstore_woocommerce_breadcrumb', 9 ); remove_action( 'woocommerce_before_main_content','woocommerce_breadcrumb', 20 ); add_filter( 'woocommerce_show_page_title', '__return_false' ); remove_action( 'woocommerce_before_shop_loop_item', 'woocommerce_template_loop_product_link_open', 10 ); remove_action( 'woocommerce_after_shop_loop_item', 'woocommerce_template_loop_product_link_close', 5 ); remove_action( 'woocommerce_before_shop_loop_item_title', 'woocommerce_show_product_loop_sale_flash', 10 ); remove_action( 'woocommerce_before_shop_loop_item_title', 'woocommerce_template_loop_product_thumbnail', 10 ); function buzzstore_woocommerce_template_loop_product_thumbnail(){ ?>
is_on_sale() ) : echo apply_filters( 'woocommerce_sale_flash', '
' . esc_html__( 'Sale!', 'buzzstore' ) . '
', $post, $product ); ?> '.esc_html__('New','buzzstore').'
'; } ?>