bricks_update_popup_settings
Overview
Updates the trigger and/or appearance settings of an existing Bricks popup. Only the provided fields are changed — other settings remain untouched. This is a partial update tool: you can change just the trigger type without affecting the popup size, or adjust the animation without changing the trigger. Ideal for iterating on popup behavior after initial creation.
Key Features
When to Use
When adjusting popup timing (delay, scroll distance, frequency limits)
When updating popup appearance (position, animation, size)
When enabling or disabling AJAX loading after observing performance impact
When changing frequency limits based on analytics
When NOT to Use
When updating the popup visual content — use bricks_update_template_content with the popup ID
When changing popup display conditions — use bricks_update_template_conditions with the popup ID
Parameters
popup_idnumberREQUIREDtriggerobjectoptionalpopup_settingsobjectoptionalCode Examples
Warning: Undefined array key "example_description" in /var/www/vhosts/mcpbricksbuilder.wecode.swiss/httpdocs/wp-content/themes/bricks/includes/elements/code.php(236) : eval()'d code on line 10
Deprecated: preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /var/www/vhosts/mcpbricksbuilder.wecode.swiss/httpdocs/wp-includes/kses.php on line 2018
Change popup trigger from load to scroll
{
"tool": "bricks_update_popup_settings",
"params": {
"popup_id": 42,
"trigger": {
"type": "scroll",
"scroll_distance": 50,
"scroll_unit": "%"
}
}
}{
"success": true,
"trigger": {
"type": "scroll",
"scroll_distance": 50,
"scroll_unit": "%",
"repeat": "once",
"cookie_days": 30
},
"popup_settings": {
"width": "600px",
"position": "center",
"animation": "zoomIn"
}
}Warning: Undefined array key "example_description" in /var/www/vhosts/mcpbricksbuilder.wecode.swiss/httpdocs/wp-content/themes/bricks/includes/elements/code.php(236) : eval()'d code on line 10
Deprecated: preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /var/www/vhosts/mcpbricksbuilder.wecode.swiss/httpdocs/wp-includes/kses.php on line 2018
Update frequency limits and enable AJAX loading
{
"tool": "bricks_update_popup_settings",
"params": {
"popup_id": 42,
"popup_settings": {
"limit_per_session": 1,
"limit_total": 3,
"ajax_load": true
}
}
}{
"success": true,
"trigger": { "type": "scroll", "scroll_distance": 50, "scroll_unit": "%" },
"popup_settings": {
"width": "600px",
"position": "center",
"limit_per_session": 1,
"limit_total": 3,
"ajax_load": true
}
}Common Mistakes
Warning: Undefined array key "fix_description" in /var/www/vhosts/mcpbricksbuilder.wecode.swiss/httpdocs/wp-content/themes/bricks/includes/elements/code.php(236) : eval()'d code on line 47
Deprecated: preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /var/www/vhosts/mcpbricksbuilder.wecode.swiss/httpdocs/wp-includes/kses.php on line 2018
Warning: Undefined array key "wrong_code" in /var/www/vhosts/mcpbricksbuilder.wecode.swiss/httpdocs/wp-content/themes/bricks/includes/elements/code.php(236) : eval()'d code on line 48
Warning: Undefined array key "right_code" in /var/www/vhosts/mcpbricksbuilder.wecode.swiss/httpdocs/wp-content/themes/bricks/includes/elements/code.php(236) : eval()'d code on line 49
Warning: Undefined array key "fix_description" in /var/www/vhosts/mcpbricksbuilder.wecode.swiss/httpdocs/wp-content/themes/bricks/includes/elements/code.php(236) : eval()'d code on line 47
Deprecated: preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /var/www/vhosts/mcpbricksbuilder.wecode.swiss/httpdocs/wp-includes/kses.php on line 2018
Warning: Undefined array key "wrong_code" in /var/www/vhosts/mcpbricksbuilder.wecode.swiss/httpdocs/wp-content/themes/bricks/includes/elements/code.php(236) : eval()'d code on line 48
Warning: Undefined array key "right_code" in /var/www/vhosts/mcpbricksbuilder.wecode.swiss/httpdocs/wp-content/themes/bricks/includes/elements/code.php(236) : eval()'d code on line 49
Tips & Warnings
Iterative approach: Create popups with basic settings first, then use bricks_update_popup_settings to fine-tune based on testing. This is faster than recreating the popup each time.
AJAX loading: Enable ajax_load if the popup has heavy content (images, forms, embeds). Disable it if the popup must appear instantly on trigger (e.g., cookie consent that must render immediately).
Display conditions: Remember that popup display conditions are managed separately via bricks_update_template_conditions, not through this tool.