WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] typo in wp-trackback.php? (2 posts)

  1. Mittineague
    Member
    Posted 7 years ago #

    I've noticed these lines in the wp-trackback.php file:

    if (empty($title) && empty($tb_url) && empty($blog_name)) {
    // If it doesn't look like a trackback at all...
    wp_redirect(get_permalink($tb_id));
    exit;
    }
    if ( !empty($tb_url) && !empty($title) && !empty($tb_url) ) {
    header('Content-Type: text/xml; charset=' . get_option('blog_charset') );

    I am wondering why !empty($tb_url) would be tested for twice. Should that line be:

    if ( !empty($tb_url) && !empty($title) && !empty($blog_name) ) {

  2. Mittineague
    Member
    Posted 7 years ago #

    I posted a ticket http://trac.wordpress.org/ticket/3665

    It looks like it should be $blog_name

    But according to the TrackBack? spec, blog_name, excerpt, and title are all optional. The only required field is url

    For now, I'd just remove the redundant check.

Topic Closed

This topic has been closed to new replies.

About this Topic