Switch language

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




edit_term_link [ WordPress Function ]

edit_term_link ( $link = '', $before = '', $after = '', $term = null, $echo = true )
Parameters:
  • (string) $link Optional. Anchor text.
  • (string) $before Optional. Display before edit link.
  • (string) $after Optional. Display after edit link.
  • (object) $term Term object
Returns:
  • (string) HTML content.
Defined at:



Display or retrieve edit term link with formatting.

Source


<?php
function edit_term_link$link ''$before ''$after ''$term null$echo true ) {
    if ( 
is_null$term ) ) {
        
$term get_queried_object();
    }

    
$tax get_taxonomy$term->taxonomy );
    if ( !
current_user_can($tax->cap->edit_terms) )
        return;

    if ( empty( 
$link ) )
        
$link __('Edit This');

    
$link '<a href="' get_edit_term_link$term->term_id$term->taxonomy ) . '" title="' $link '">' $link '</a>';
    
$link $before apply_filters'edit_term_link'$link$term->term_id ) . $after;

    if ( 
$echo )
        echo 
$link;
    else
        return 
$link;
}
?>

Examples [ wp-snippets.com ]

Google Arama Sonuçlarý

Dahasý ...

Kullanýcý Tartýþmalarý [ wordpress.org ]

- Bulunamadý -

Yeni bir konu yaz ...

0 User Note(s)

Henüz yok. Ýlk sen ol!

Yeni Ekle ...



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