Make WordPress Core

Ticket #9730: 9730-misc.diff

File 9730-misc.diff, 4.5 KB (added by Denis-de-Bernardy, 16 years ago)

wp-app and xml-rpc

  • wp-app.php

     
    11061106                $self_page = $page > 1 ? $page : NULL;
    11071107?><feed xmlns="<?php echo $this->ATOM_NS ?>" xmlns:app="<?php echo $this->ATOMPUB_NS ?>" xml:lang="<?php echo get_option('rss_language'); ?>">
    11081108<id><?php $this->the_entries_url() ?></id>
    1109 <updated><?php echo mysql2date('Y-m-d\TH:i:s\Z', get_lastpostmodified('GMT')); ?></updated>
     1109<updated><?php echo mysql2date('Y-m-d\TH:i:s\Z', get_lastpostmodified('GMT'), false); ?></updated>
    11101110<title type="text"><?php bloginfo_rss('name') ?></title>
    11111111<subtitle type="text"><?php bloginfo_rss("description") ?></subtitle>
    11121112<link rel="first" type="<?php echo $this->ATOM_CONTENT_TYPE ?>" href="<?php $this->the_entries_url() ?>" />
  • xmlrpc.php

     
    523523                        $allow_pings = pings_open($page->ID) ? 1 : 0;
    524524
    525525                        // Format page date.
    526                         $page_date = mysql2date("Ymd\TH:i:s", $page->post_date);
    527                         $page_date_gmt = mysql2date("Ymd\TH:i:s", $page->post_date_gmt);
     526                        $page_date = mysql2date("Ymd\TH:i:s", $page->post_date, false);
     527                        $page_date_gmt = mysql2date("Ymd\TH:i:s", $page->post_date_gmt, false);
    528528
    529529                        // Pull the categories info together.
    530530                        $categories = array();
     
    799799                // The date needs to be formated properly.
    800800                $num_pages = count($page_list);
    801801                for($i = 0; $i < $num_pages; $i++) {
    802                         $post_date = mysql2date("Ymd\TH:i:s", $page_list[$i]->post_date);
    803                         $post_date_gmt = mysql2date("Ymd\TH:i:s", $page_list[$i]->post_date_gmt);
     802                        $post_date = mysql2date("Ymd\TH:i:s", $page_list[$i]->post_date, false);
     803                        $post_date_gmt = mysql2date("Ymd\TH:i:s", $page_list[$i]->post_date_gmt, false);
    804804
    805805                        $page_list[$i]->dateCreated = new IXR_Date($post_date);
    806806                        $page_list[$i]->date_created_gmt = new IXR_Date($post_date_gmt);
     
    10471047                        return new IXR_Error( 404, __( 'Invalid comment ID.' ) );
    10481048
    10491049                // Format page date.
    1050                 $comment_date = mysql2date("Ymd\TH:i:s", $comment->comment_date);
    1051                 $comment_date_gmt = mysql2date("Ymd\TH:i:s", $comment->comment_date_gmt);
     1050                $comment_date = mysql2date("Ymd\TH:i:s", $comment->comment_date, false);
     1051                $comment_date_gmt = mysql2date("Ymd\TH:i:s", $comment->comment_date_gmt, false);
    10521052
    10531053                if ( 0 == $comment->comment_approved )
    10541054                        $comment_status = 'hold';
     
    16791679
    16801680                $struct = array(
    16811681                        'userid'    => $post_data['post_author'],
    1682                         'dateCreated' => new IXR_Date(mysql2date('Ymd\TH:i:s', $post_data['post_date'])),
     1682                        'dateCreated' => new IXR_Date(mysql2date('Ymd\TH:i:s', $post_data['post_date'], false)),
    16831683                        'content'     => $content,
    16841684                        'postid'  => $post_data['ID']
    16851685                );
     
    17211721                        if( !current_user_can( 'edit_post', $entry['ID'] ) )
    17221722                                continue;
    17231723
    1724                         $post_date = mysql2date('Ymd\TH:i:s', $entry['post_date']);
     1724                        $post_date = mysql2date('Ymd\TH:i:s', $entry['post_date'], false);
    17251725                        $categories = implode(',', wp_get_post_categories($entry['ID']));
    17261726
    17271727                        $content  = '<title>'.stripslashes($entry['post_title']).'</title>';
     
    25712571                $postdata = wp_get_single_post($post_ID, ARRAY_A);
    25722572
    25732573                if ($postdata['post_date'] != '') {
    2574                         $post_date = mysql2date('Ymd\TH:i:s', $postdata['post_date']);
    2575                         $post_date_gmt = mysql2date('Ymd\TH:i:s', $postdata['post_date_gmt']);
     2574                        $post_date = mysql2date('Ymd\TH:i:s', $postdata['post_date'], false);
     2575                        $post_date_gmt = mysql2date('Ymd\TH:i:s', $postdata['post_date_gmt'], false);
    25762576
    25772577                        $categories = array();
    25782578                        $catids = wp_get_post_categories($post_ID);
     
    26872687                        if( !current_user_can( 'edit_post', $entry['ID'] ) )
    26882688                                continue;
    26892689
    2690                         $post_date = mysql2date('Ymd\TH:i:s', $entry['post_date']);
    2691                         $post_date_gmt = mysql2date('Ymd\TH:i:s', $entry['post_date_gmt']);
     2690                        $post_date = mysql2date('Ymd\TH:i:s', $entry['post_date'], false);
     2691                        $post_date_gmt = mysql2date('Ymd\TH:i:s', $entry['post_date_gmt'], false);
    26922692
    26932693                        $categories = array();
    26942694                        $catids = wp_get_post_categories($entry['ID']);
     
    29222922                        if( !current_user_can( 'edit_post', $entry['ID'] ) )
    29232923                                continue;
    29242924
    2925                         $post_date = mysql2date('Ymd\TH:i:s', $entry['post_date']);
    2926                         $post_date_gmt = mysql2date('Ymd\TH:i:s', $entry['post_date_gmt']);
     2925                        $post_date = mysql2date('Ymd\TH:i:s', $entry['post_date'], false);
     2926                        $post_date_gmt = mysql2date('Ymd\TH:i:s', $entry['post_date_gmt'], false);
    29272927
    29282928                        $struct[] = array(
    29292929                                'dateCreated' => new IXR_Date($post_date),