Make WordPress Core


Ignore:
Timestamp:
05/18/2005 03:17:55 AM (21 years ago)
Author:
ryan
Message:

Don't attempt to trackback an empty string. Fix file path in wp_get_http_headers(). This avoids 'File does not exist' server messages when processing enclosures.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/functions.php

    r2611 r2612  
    634634function trackback($trackback_url, $title, $excerpt, $ID) {
    635635        global $wpdb, $wp_version;
     636
     637        if (empty($trackback_url))
     638                return;
     639
    636640        $title = urlencode($title);
    637641        $excerpt = urlencode($excerpt);
    … …  
    792796        set_time_limit( 60 );
    793797        $parts = parse_url( $url );
    794         $file  = $parts['path'] . $parts['query'];
     798        $file  = $parts['path'] . ($parts['query'] ? '?'.$parts['query'] : '');
    795799        $host  = $parts['host'];
    796800        if ( !isset( $parts['port'] ) )
Note: See TracChangeset for help on using the changeset viewer.