Make WordPress Core

Ticket #23917: 23917.patch

File 23917.patch, 4.6 KB (added by ocean90, 11 years ago)
  • wp-includes/post-template.php

     
    13131313        /* translators: revision date format, see http://php.net/date */
    13141314        $datef = _x( 'j F, Y @ G:i', 'revision date format');
    13151315        /* translators: 1: date */
    1316         $autosavef = __( '%1$s [Autosave]' );
     1316        $autosavef = _x( '%1$s [Autosave]', 'post revision title extra' );
    13171317        /* translators: 1: date */
    1318         $currentf  = __( '%1$s [Current Revision]' );
     1318        $currentf  = _x( '%1$s [Current Revision]', 'post revision title extra' );
    13191319
    13201320        $date = date_i18n( $datef, strtotime( $revision->post_modified ) );
    13211321        if ( $link && current_user_can( 'edit_post', $revision->ID ) && $link = get_edit_post_link( $revision->ID ) )
  • wp-admin/includes/ajax-actions.php

     
    22452245                        $date
    22462246                );
    22472247
     2248                /* translators: 1: date */
    22482249                $autosavef = _x( '%1$s [Autosave]', 'post revision title extra' );
     2250                /* translators: 1: date */
    22492251                $currentf  = _x( '%1$s [Current Revision]', 'post revision title extra' );
    22502252
    22512253                if ( ! $post = get_post( $post_id ) )
  • wp-admin/js/revisions.js

     
    11window.wp = window.wp || {};
    22
    33(function($) {
    4         var Revision, Revisions, Diff, l10n, revisions;
     4        var Revision, Revisions, Diff, revisions;
    55
    66        revisions = wp.revisions = function() {
    77                Diff = revisions.Diff = new Diff();
     
    99
    1010        _.extend( revisions, { model: {}, view: {}, controller: {} } );
    1111
    12         // Link any localized strings.
    13         l10n = revisions.model.l10n = typeof wpRevisionsL10n === 'undefined' ? {} : wpRevisionsL10n;
     12        // Link settings.
     13        revisions.model.settings = typeof wpRevisionsSettings === 'undefined' ? {} : wpRevisionsSettings;
    1414
    15         // Link any settings.
    16         revisions.model.settings = l10n.settings || {};
    17         delete l10n.settings;
    1815
    19 
    2016        /**
    2117         * ========================================================================
    2218         * CONTROLLERS
  • wp-admin/revision.php

     
    7878
    7979wp_enqueue_script( 'revisions' );
    8080
    81 $strings = array(
    82         'diffFromTitle' => _x( 'From: %s', 'revision from title'  ),
    83         'diffToTitle'   => _x( 'To: %s', 'revision to title' )
    84 );
    8581
    8682$settings = array(
    8783        'post_id'     => $post->ID,
     
    8985        'revision_id' => $revision_id
    9086);
    9187
    92 $strings['settings'] = $settings;
    93 wp_localize_script( 'revisions', 'wpRevisionsL10n', $strings );
     88wp_localize_script( 'revisions', 'wpRevisionsSettings', $settings );
    9489
    9590require_once( './admin-header.php' );
    9691
     
    125120
    126121        <div id="diff-header">
    127122                <div id="diff-header-from" class="diff-header">
    128                         <div id="diff-title-from-current-version" class="diff-title">
    129                                 <?php printf( '<strong>%1$s</strong> %2$s.' , __( 'From:' ), __( 'the current version' ) ); ?>
    130                         </div>
    131 
    132123                        <div id="diff-title-from" class="diff-title">
    133                                 <strong><?php _e( 'From:' ); ?></strong> {{{ data.titleFrom }}}
     124                                <strong><?php _ex( 'From:', 'Followed by post revision info' ); ?></strong> {{{ data.titleFrom }}}
    134125                        </div>
    135126                </div>
    136127
    137128                <div id="diff-header-to" class="diff-header">
    138129                        <div id="diff-title-to" class="diff-title">
    139                                 <strong><?php _e( 'To:' ); ?></strong> {{{ data.titleTo }}}
     130                                <strong><?php _e( 'To:', 'Followed by post revision info' ); ?></strong> {{{ data.titleTo }}}
    140131                        </div>
    141132
    142133                        <input type="button" id="restore-revision" class="button button-primary" data-restore-link="{{{ data.restoreLink }}}" value="<?php esc_attr_e( 'Restore This Revision' )?>" />
     
    150141
    151142<script id="tmpl-revision-interact" type="text/html">
    152143        <div id="diff-previous-revision">
    153                 <input class="button" type="button" id="previous" value="<?php esc_attr_e( 'Previous' ); ?>" />
     144                <input class="button" type="button" id="previous" value="<?php echo esc_attr_x( 'Previous', 'Button label for a previous revision' ); ?>" />
    154145        </div>
    155146
    156147        <div id="diff-next-revision">
    157                 <input class="button" type="button" id="next" value="<?php esc_attr_e( 'Next' ); ?>" />
     148                <input class="button" type="button" id="next" value="<?php echo esc_attr_x( 'Next', 'Button label for a next revision' ); ?>" />
    158149        </div>
    159150
    160151        <div id="diff-slider" class="wp-slider"></div>