Filterable Configure
Filterable Configure
If you do not want to touch framework files, you can use add_filter
method. You can see all filters for options below.
Hook
Hook Name
add_filter
wpsf_framework_options
add_filter
wpsf_framework_settings
add_filter
wpsf_metabox_options
add_filter
wpsf_taxonomy_options
add_filter
wpsf_shortcode_options
add_filter
wpsf_customize_options
// framework options filter example
function extra_wpsf_framework_options( $options ) {
$options = array(); // remove old options
$options[] = array(
'name' => 'section_unique_id',
'title' => 'First Section',
'icon' => 'fa fa-heart',
'fields' => array(
array(
'id' => 'option_id',
'type' => 'text',
'title' => 'First Option',
),
array(
'id' => 'another_option_id',
'type' => 'textarea',
'title' => 'Secondary Option',
),
)
);
return $options;
}
add_filter( 'wpsf_framework_options', 'extra_wpsf_framework_options' );
Last updated