This filter allows you to change what add to cart trigger is being used.
Argument | Type | Description |
$trigger | string | Returns drawer by default. Other options are popup , bar and none . If you set the trigger to none then no popup will be triggered. |
/**
* Change the add to cart trigger. "none" will not open any popup.
*
* @param string $trigger The add to cart trigger, default is "drawer"
*/
function my_prefix_cartpops_add_to_cart_trigger( $trigger ) {
$trigger = 'none';
return $trigger;
}
add_filter( 'cartpops_add_to_cart_trigger', 'my_prefix_cartpops_add_to_cart_trigger', 10, 1 );