WordPress at a glance
function is not described

WP_Customize_Widgets::get_captured_option() protected WP 4.2.0

Retrieves the option that was captured from being saved.

{} It's a method of the class: WP_Customize_Widgets{}

No Hooks.


Mixed. Value set for the option.


// protected - for code of main (parent) or child class
$result = $this->get_captured_option( $option_name, $default );
$option_name(string) (required)
Option name.
Default false.
Default: value to return if the option does not exist


Since 4.2.0 Introduced.

Code of WP_Customize_Widgets::get_captured_option() WP 5.7.2

protected function get_captured_option( $option_name, $default = false ) {
	if ( array_key_exists( $option_name, $this->_captured_options ) ) {
		$value = $this->_captured_options[ $option_name ];
	} else {
		$value = $default;
	return $value;