the_widget

FUNCTION wp-includes\widgets.php (ligne 1196) github
Outputs an arbitrary widget as a template tag.

Paramètres

Entrée :
$widget, $instance = array(
Sortie :
@param string $widget   The widget's PHP class name (see class-wp-widget.php).
@param array  $instance Optional. The widget's instance settings. Default empty array.
@param array  $args {

Utilisation

// Utilisation de la fonction the_widget
$result = the_widget($widget, $instance = array();

if ($result) {
    // Votre logique ici
}

Actualités

Chargement des actualités...