wp_error_added WordPress Action Hook

The wp_error_added hook is triggered when an error is added to a WP_Error object.

do_action( 'wp_error_added', string|int $code, string $message, mixed $data, WP_Error $wp_error ) #

Fires when an error is added to a WP_Error object.


Parameters

$code

(string|int)Error code.

$message

(string)Error message.

$data

(mixed)Error data. Might be empty.

$wp_error

(WP_Error)The WP_Error object.


Top ↑

Source

File: wp-includes/class-wp-error.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
5.6.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.