Make WordPress Core

Changeset 496


Ignore:
Timestamp:
10/30/2003 01:54:05 AM (21 years ago)
Author:
mikelittle
Message:

Fix for edit timestamp of comments.

Location:
trunk/wp-admin
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/b2edit.php

    r479 r496  
    407407            $mn = ($mn > 59) ? $mn - 60 : $mn;
    408408            $ss = ($ss > 59) ? $ss - 60 : $ss;
    409             $datemodif = ", comment_date = 'aa-$mm-$jj $hh:$mn:$ss'";
     409            $datemodif = ", comment_date = '$aa-$mm-$jj $hh:$mn:$ss'";
    410410        } else {
    411411            $datemodif = '';
  • trunk/wp-admin/wp-post.php

    r489 r496  
    151151
    152152    case 'edit':
    153     $title = 'Edit';
     153        $title = 'Edit';
    154154
    155155        $standalone = 0;
     
    324324
    325325    case 'editcomment':
    326     $title = 'Edit Comment';
     326        $title = 'Edit Comment';
    327327        $standalone = 0;
    328328        require_once ('b2header.php');
     
    347347        $standalone = 1;
    348348        require_once('./b2header.php');
    349        
     349
    350350        if ($user_level == 0)
    351351            die ('Cheatin’ uh?');
    352        
     352
    353353        $comment = $HTTP_GET_VARS['comment'];
    354354        $p = $HTTP_GET_VARS['p'];
    355355        $commentdata = get_commentdata($comment) or die('Oops, no comment with this ID. <a href="b2edit.php">Go back</a>!');
    356        
     356
    357357        $result = $wpdb->query("DELETE FROM $tablecomments WHERE comment_ID=$comment");
    358        
     358
    359359        header ('Location: ' . $HTTP_SERVER_VARS['HTTP_REFERER']);
    360        
     360
    361361        break;
    362362
     
    389389            $mn = ($mn > 59) ? $mn - 60 : $mn;
    390390            $ss = ($ss > 59) ? $ss - 60 : $ss;
    391             $datemodif = ", comment_date = 'aa-$mm-$jj $hh:$mn:$ss'";
     391            $datemodif = ", comment_date = '$aa-$mm-$jj $hh:$mn:$ss'";
    392392        } else {
    393393            $datemodif = '';
     
    404404            WHERE comment_ID = $comment_ID"
    405405            );
    406        
     406
    407407        $referredby = $HTTP_POST_VARS['referredby'];
    408408        if (!empty($referredby)) header('Location: ' . $referredby);
     
    429429                    $i = 0;
    430430                    foreach ($drafts as $draft) {
    431                         if (0 != $i) echo ', ';
    432                         $draft->post_title = stripslashes($draft->post_title);   if ($draft->post_title == '') $draft->post_title = 'post-'.$draft->ID;
     431                        if (0 != $i)
     432                            echo ', ';
     433                        $draft->post_title = stripslashes($draft->post_title);
     434                        if ($draft->post_title == '')
     435                            $draft->post_title = 'post-'.$draft->ID;
    433436                        echo "<a href='b2edit.php?action=edit&amp;post=$draft->ID' title='Edit this draft'>$draft->post_title</a>";
    434437                        ++$i;
     
    460463
    461464        }
    462        
     465
    463466        break;
    464467} // end switch
Note: See TracChangeset for help on using the changeset viewer.