WP_Customize_Selective_Refresh::handle_error( int $errno, string $errstr, string $errfile = null, string $errline = null )

Handles PHP errors triggered during rendering the partials.


Description Description

These errors will be relayed back to the client in the Ajax response.


Parameters Parameters

$errno

(int) (Required) Error number.

$errstr

(string) (Required) Error string.

$errfile

(string) (Optional) Error file.

Default value: null

$errline

(string) (Optional) Error line.

Default value: null


Top ↑

Return Return

(true) Always true.


Top ↑

Source Source

File: wp-includes/customize/class-wp-customize-selective-refresh.php

	public function handle_error( $errno, $errstr, $errfile = null, $errline = null ) {
		$this->triggered_errors[] = array(
			'partial'      => $this->current_partial_id,
			'error_number' => $errno,
			'error_string' => $errstr,
			'error_file'   => $errfile,
			'error_line'   => $errline,
		);
		return true;
	}

Top ↑

Changelog Changelog

Changelog
Version Description
4.5.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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