Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Disable Beaver Builder global padding and margin
<?php
/**
* Set Beaver Builder defaults
*
* @param {object} $defaults The default settings.
* @param {object} $form)_type The module settings.
* @return $defaults
*/
function grd_set_bb_defaults( $defaults, $form_type ) {
if ( 'global' == $form_type ) {
$defaults->row_padding = '0';
$defaults->row_width_default = 'full';
$defaults->row_content_width_default = 'full';
$defaults->module_margins = '0';
}
return $defaults;
}
add_filter( 'fl_builder_settings_form_defaults', grd_set_bb_defaults, 10, 2 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.