Ticket #30506: 30506.patch
File 30506.patch, 5.5 KB (added by , 8 years ago) |
---|
-
src/wp-admin/includes/template.php
725 725 $year = '<label><span class="screen-reader-text">' . __( 'Year' ) . '</span><input type="text" ' . ( $multi ? '' : 'id="aa" ' ) . 'name="aa" value="' . $aa . '" size="4" maxlength="4"' . $tab_index_attribute . ' autocomplete="off" /></label>'; 726 726 $hour = '<label><span class="screen-reader-text">' . __( 'Hour' ) . '</span><input type="text" ' . ( $multi ? '' : 'id="hh" ' ) . 'name="hh" value="' . $hh . '" size="2" maxlength="2"' . $tab_index_attribute . ' autocomplete="off" /></label>'; 727 727 $minute = '<label><span class="screen-reader-text">' . __( 'Minute' ) . '</span><input type="text" ' . ( $multi ? '' : 'id="mn" ' ) . 'name="mn" value="' . $mn . '" size="2" maxlength="2"' . $tab_index_attribute . ' autocomplete="off" /></label>'; 728 /* translators: 1: hour, 2: minute */ 729 $time = '<span dir="ltr">' . sprintf( __( '%1$s:%2$s' ), $hour, $minute ) . '</span>'; 728 730 729 731 echo '<div class="timestamp-wrap">'; 730 /* translators: 1: month, 2: day, 3: year, 4: hour, 5: minute */731 printf( __( '%1$s %2$s, %3$s @ %4$s :%5$s' ), $month, $day, $year, $hour, $minute );732 /* translators: 1: month, 2: day, 3: year, 4: time */ 733 printf( __( '%1$s %2$s, %3$s @ %4$s' ), $month, $day, $year, $time ); 732 734 733 735 echo '</div><input type="hidden" id="ss" name="ss" value="' . $ss . '" />'; 734 736 -
src/wp-admin/js/comment.js
34 34 35 35 $timestampdiv.find('.save-timestamp').click( function( event ) { // crazyhorse - multiple ok cancels 36 36 var aa = $('#aa').val(), mm = $('#mm').val(), jj = $('#jj').val(), hh = $('#hh').val(), mn = $('#mn').val(), 37 newD = new Date( aa, mm - 1, jj, hh, mn ); 37 newD = new Date( aa, mm - 1, jj, hh, mn ), 38 commentTime; 38 39 39 40 event.preventDefault(); 40 41 … … 45 46 $timestampwrap.removeClass( 'form-invalid' ); 46 47 } 47 48 49 commentTime = commentL10n.timeFormat 50 .replace( '%1$s', ( '00' + hh ).slice( -2 ) ) 51 .replace( '%2$s', ( '00' + mn ).slice( -2 ) ); 52 48 53 $timestamp.html( 49 54 commentL10n.submittedOn + ' <b>' + 50 55 commentL10n.dateFormat … … 51 56 .replace( '%1$s', $( 'option[value="' + mm + '"]', '#mm' ).attr( 'data-text' ) ) 52 57 .replace( '%2$s', parseInt( jj, 10 ) ) 53 58 .replace( '%3$s', aa ) 54 .replace( '%4$s', ( '00' + hh ).slice( -2 ) ) 55 .replace( '%5$s', ( '00' + mn ).slice( -2 ) ) + 59 .replace( '%4$s', commentTime ) + 56 60 '</b> ' 57 61 ); 58 62 -
src/wp-admin/js/post.js
720 720 721 721 var attemptedDate, originalDate, currentDate, publishOn, postStatus = $('#post_status'), 722 722 optPublish = $('option[value="publish"]', postStatus), aa = $('#aa').val(), 723 mm = $('#mm').val(), jj = $('#jj').val(), hh = $('#hh').val(), mn = $('#mn').val(); 723 mm = $('#mm').val(), jj = $('#jj').val(), hh = $('#hh').val(), mn = $('#mn').val(), 724 publishTime; 724 725 725 726 attemptedDate = new Date( aa, mm - 1, jj, hh, mn ); 726 727 originalDate = new Date( $('#hidden_aa').val(), $('#hidden_mm').val() -1, $('#hidden_jj').val(), $('#hidden_hh').val(), $('#hidden_mn').val() ); … … 751 752 // Re-set to the current value. 752 753 $('#timestamp').html(stamp); 753 754 } else { 755 publishTime = postL10n.timeFormat 756 .replace( '%1$s', ( '00' + hh ).slice( -2 ) ) 757 .replace( '%2$s', ( '00' + mn ).slice( -2 ) ); 758 754 759 $('#timestamp').html( 755 760 '\n' + publishOn + ' <b>' + 756 761 postL10n.dateFormat … … 757 762 .replace( '%1$s', $( 'option[value="' + mm + '"]', '#mm' ).attr( 'data-text' ) ) 758 763 .replace( '%2$s', parseInt( jj, 10 ) ) 759 764 .replace( '%3$s', aa ) 760 .replace( '%4$s', ( '00' + hh ).slice( -2 ) ) 761 .replace( '%5$s', ( '00' + mn ).slice( -2 ) ) + 765 .replace( '%4$s', publishTime ) + 762 766 '</b> ' 763 767 ); 764 768 } -
src/wp-includes/script-loader.php
556 556 'publishOn' => __('Publish on:'), 557 557 'publishOnFuture' => __('Schedule for:'), 558 558 'publishOnPast' => __('Published on:'), 559 /* translators: 1: month, 2: day, 3: year, 4: hour, 5: minute */ 560 'dateFormat' => __('%1$s %2$s, %3$s @ %4$s:%5$s'), 559 /* translators: 1: month, 2: day, 3: year, 4: time */ 560 'dateFormat' => __( '%1$s %2$s, %3$s @ %4$s' ), 561 /* translators: 1: hour, 2: minute */ 562 'timeFormat' => __( '%1$s:%2$s' ), 561 563 'showcomm' => __('Show more comments'), 562 564 'endcomm' => __('No more comments found.'), 563 565 'publish' => __('Publish'), … … 595 597 $scripts->add_data( 'comment', 'group', 1 ); 596 598 did_action( 'init' ) && $scripts->localize( 'comment', 'commentL10n', array( 597 599 'submittedOn' => __( 'Submitted on:' ), 598 /* translators: 1: month, 2: day, 3: year, 4: hour, 5: minute */ 599 'dateFormat' => __( '%1$s %2$s, %3$s @ %4$s:%5$s' ) 600 /* translators: 1: month, 2: day, 3: year, 4: time */ 601 'dateFormat' => __( '%1$s %2$s, %3$s @ %4$s' ), 602 /* translators: 1: hour, 2: minute */ 603 'timeFormat' => __( '%1$s:%2$s' ), 600 604 ) ); 601 605 602 606 $scripts->add( 'admin-gallery', "/wp-admin/js/gallery$suffix.js", array( 'jquery-ui-sortable' ) );