get_delete_post_link

FUNCTION wp-includes\link-template.php (ligne 1533) github
Filters the post edit link anchor tag.

Paramètres

Entrée :
$post = 0, $deprecated = '', $force_delete = false
Sortie :
@param string $link    Anchor tag for the edit link.
@param int    $post_id Post ID.
@param string $text    Anchor text.
@param int|WP_Post $post         Optional. Post ID or post object. Default is the global `$post`.
@param string      $deprecated   Not used.
@param bool        $force_delete Optional. Whether to bypass Trash and force deletion. Default false.
@return string|void The delete post link URL for the given post.

Utilisation

// Utilisation de la fonction get_delete_post_link
$result = get_delete_post_link($post = 0, $deprecated = '', $force_delete = false);

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

Actualités

Chargement des actualités...