WordPress at a glance
filter is not described

customize_value_(id_base) filter-hook . WP 3.4.0

Filters a Customize setting value not handled as a theme_mod or option.

The dynamic portion of the hook name, $id_base, refers to the base slug of the setting name, initialized from $this->id_data['base'].

For settings handled as theme_mods or options, see those corresponding functions for available hooks.

Usage

add_filter( 'customize_value_(id_base)', 'filter_function_name_2347', 10, 2 );
function filter_function_name_2347( $default, $this ){
	// filter...

	return $default;
}
$default(mixed)
The setting default value.
Default: ''
$this(WP_Customize_Setting)
The setting instance.

Notes

  • Since 4.6.0 Added the $this setting instance as the second parameter.

Where the hook is called

WP_Customize_Setting::value()
WP_Customize_Custom_CSS_Setting::value()
wp-includes/class-wp-customize-setting.php 753
$value = apply_filters( "customize_value_{$id_base}", $value, $this );
wp-includes/customize/class-wp-customize-custom-css-setting.php 140
$value = apply_filters( "customize_value_{$id_base}", $value, $this );

Where the hook is used (in WP core)

wp-includes/class-wp-customize-widgets.php 276
add_filter( 'customize_value_old_sidebars_widgets_data', array( $this, 'filter_customize_value_old_sidebars_widgets_data' ) );