Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Woo: условие вывода для похожих товаров
add_filter( 'woocommerce_variable_price_html', 'bbloomer_remove_variation_price', 10, 2 );
function bbloomer_remove_variation_price( $price ) {
global $woocommerce_loop;
if ( is_product() && $woocommerce_loop['name'] == 'related' ) {
$price = '';
}
return $price;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment