sequra_can_display_widgets
Hook
Filter
Allow modifying the seQura availability at product page
Description
Use this to modify the current availability for displaying promotional components on the product page.
Parameter | Type | Description |
---|---|---|
$is_available | bool | Define if promotional components are available for the product |
$product | WC_Product | Product instance |
Changelog
Version | Description |
---|---|
3.0.0 | Introduced |
Usage Example
add_filter('sequra_can_display_widgets', function($is_available, $product){
if($product->get_id() === 999){
return true; // Force to show widgets for the product with ID 999.
}
return $is_available;
}, 10, 2);
Updated about 1 month ago