WP_Customize_Date_Time_Control::json(): array

In this article

Export data to JS.

Return

array

Source

public function json() {
	$data = parent::json();

	$data['maxYear']          = (int) $this->max_year;
	$data['minYear']          = (int) $this->min_year;
	$data['allowPastDate']    = (bool) $this->allow_past_date;
	$data['twelveHourFormat'] = (bool) $this->twelve_hour_format;
	$data['includeTime']      = (bool) $this->include_time;

	return $data;
}

Changelog

VersionDescription
4.9.0Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.