Switch language

wpseek.com
A WordPress-centric search engine for devs and theme authors




get_tag_link [ WordPress Function ]

get_tag_link ( $tag )
Parameters:
  • (int|object) $tag Tag ID or object.
See:
Returns:
  • (string) Link on success, empty string if tag does not exist.
Defined at:



Retrieve the link to the tag.

Source


<?php
function get_tag_link$tag ) {
    if ( ! 
is_object$tag ) )
        
$tag = (int) $tag;

    
$tag get_term_link$tag'post_tag' );

    if ( 
is_wp_error$tag ) )
        return 
'';

    return 
$tag;
}
?>

Examples [ wp-snippets.com ]

Google Arama Sonuçlarý

Dahasý ...

0 User Note(s)

Henüz yok. Ýlk sen ol!

Yeni Ekle ...



HTML5 Powered with CSS3 / Styling, Performance & Integration, and Semantics