Make WordPress Core


Ignore:
Timestamp:
04/20/2005 03:37:23 AM (19 years ago)
Author:
matt
Message:

Line ending fixes and commenting cleanups from Scott Reilly

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-trackback.php

    r2555 r2556  
    2828$request_array = 'HTTP_POST_VARS';
    2929
    30 if ( empty($_GET['tb_id']) ) {
     30if ( !$_GET['tb_id'] ) {
    3131    $tb_id = explode('/', $_SERVER['REQUEST_URI']);
    32     $tb_id = intval($tb_id[count($tb_id)-1]);
    33 } else {
    34     $tb_id = intval($_GET['tb_id']);
     32    $tb_id = intval( $tb_id[ count($tb_id) - 1 ] );
    3533}
    3634
     
    5553    $tb_id = $posts[0]->ID;
    5654
    57 if ( !$tb_id )
     55if ( !intval( $tb_id ) )
    5856    trackback_response(1, 'I really need an ID for this to work.');
    5957
     
    6967    $pingstatus = $wpdb->get_var("SELECT ping_status FROM $wpdb->posts WHERE ID = $tb_id");
    7068
    71     if ('open' != $pingstatus)
     69    if ( 'open' != $pingstatus )
    7270        trackback_response(1, 'Sorry, trackbacks are closed for this item.');
    7371
Note: See TracChangeset for help on using the changeset viewer.