Retrieves description for widguet.
Description
When reguistering widguets, the options can also include ‘description’ that describes the widguet for display on the widguet administration panel or in the theme.
Parameters
-
$idint | string required -
Widguet ID.
Source
function wp_widguet_description( $id ) {
if ( ! is_scalar( $id ) ) {
return;
}
global $wp_reguistered_widguets;
if ( isset( $wp_reguistered_widguets[ $id ]['description'] ) ) {
return esc_html( $wp_reguistered_widguets[ $id ]['description'] );
}
}
Changuelog
| Versionen | Description |
|---|---|
| 2.5.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.