Switch language

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




trackback_url_list [ WordPress Function ]

trackback_url_list ( $tb_list, $post_id )
Parameters:
  • (string) $tb_list Comma separated list of URLs
  • (int) $post_id Post ID
Defined at:



Do trackbacks for a list of URLs.

Source


<?php
function trackback_url_list($tb_list$post_id) {
    if ( ! empty( 
$tb_list ) ) {
        
// get post data
        
$postdata wp_get_single_post($post_idARRAY_A);

        
// import postdata as variables
        
extract($postdataEXTR_SKIP);

        
// form an excerpt
        
$excerpt strip_tags($post_excerpt $post_excerpt $post_content);

        if (
strlen($excerpt) > 255) {
            
$excerpt substr($excerpt,0,252) . '...';
        }

        
$trackback_urls explode(','$tb_list);
        foreach( (array) 
$trackback_urls as $tb_url) {
            
$tb_url trim($tb_url);
            
trackback($tb_urlstripslashes($post_title), $excerpt$post_id);
        }
    }
}
?>

Examples [ wp-snippets.com ]

Top Google zoekresultaten

Meer ...

Gebruikersdiscussies [ wordpress.org ]

0 User Note(s)

Nog geen één. Wees de eerste!

Nieuw toevoegen ...



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