Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save SashkoWooTeam/60179f0ee8978947666c5490b38b0b44 to your computer and use it in GitHub Desktop.

Select an option

Save SashkoWooTeam/60179f0ee8978947666c5490b38b0b44 to your computer and use it in GitHub Desktop.
Add JetSmartFilters compatibility with Asrta Theme
add_action( 'jet-smart-filters/providers/epro-archive-products/before-ajax-content', 'jet_smart_filters_astra_compatibility', 1 );
function jet_smart_filters_astra_compatibility(){
if( class_exists( 'Astra_Woocommerce' ) ){
$astra = new Astra_Woocommerce();
if ( ! apply_filters( 'astra_woo_shop_product_structure_override', false ) ) {
$astra->shop_customization();
}
remove_action( 'woocommerce_after_shop_loop_item_title', 'woocommerce_template_loop_rating', 5 );
remove_action( 'woocommerce_shop_loop_item_title', 'woocommerce_template_loop_product_title', 10 );
remove_action( 'woocommerce_after_shop_loop_item_title', 'woocommerce_template_loop_price', 10 );
remove_action( 'woocommerce_before_shop_loop_item_title', 'woocommerce_show_product_loop_sale_flash', 10 );
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment