From 0bf194de3ba4214a36e6dcc0f0998077fea4a539 Mon Sep 17 00:00:00 2001 From: ryan Date: Mon, 2 Mar 2009 19:20:19 +0000 Subject: [PATCH] Use _x() and extracted comments. Props nbachiyski. see #9112 git-svn-id: http://svn.automattic.com/wordpress/trunk@10680 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/comment.php | 2 +- wp-admin/edit-form-advanced.php | 7 +++++-- wp-admin/edit-form-comment.php | 9 +++++---- wp-admin/edit-page-form.php | 3 ++- wp-admin/edit-pages.php | 4 +++- wp-admin/gears-manifest.php | 6 ++++++ wp-admin/includes/dashboard.php | 17 ++++++++++------- wp-admin/includes/template.php | 31 +++++++++++++++++++++---------- wp-admin/includes/widgets.php | 3 ++- wp-admin/menu.php | 15 ++++++++++----- wp-admin/themes.php | 4 +++- wp-admin/upload.php | 8 ++++---- 12 files changed, 72 insertions(+), 37 deletions(-) diff --git a/wp-admin/comment.php b/wp-admin/comment.php index 129d621137..1fb137d92f 100644 --- a/wp-admin/comment.php +++ b/wp-admin/comment.php @@ -123,7 +123,7 @@ if ( 'spam' == $_GET['dt'] ) { - + comment_content; ?> diff --git a/wp-admin/edit-form-advanced.php b/wp-admin/edit-form-advanced.php index a0dff5db0d..1eb3365e2e 100644 --- a/wp-admin/edit-form-advanced.php +++ b/wp-admin/edit-form-advanced.php @@ -191,7 +191,8 @@ if ( 'private' == $post->post_status ) { ID ) { if ( 'future' == $post->post_status ) { // scheduled for publishing at a future date $stamp = __('Scheduled for: %1$s'); @@ -468,7 +469,9 @@ function post_comment_meta_box($post) { - + + + diff --git a/wp-admin/edit-form-comment.php b/wp-admin/edit-form-comment.php index 531db65b08..b32d53b7d7 100644 --- a/wp-admin/edit-form-comment.php +++ b/wp-admin/edit-form-comment.php @@ -48,14 +48,15 @@ $url = attribute_escape( $comment->comment_author_url );
-
-
- +
+
+
%1$s'); $date = date_i18n( $datef, strtotime( $comment->comment_date ) ); ?> diff --git a/wp-admin/edit-page-form.php b/wp-admin/edit-page-form.php index 18658044ef..1050c2baae 100644 --- a/wp-admin/edit-page-form.php +++ b/wp-admin/edit-page-form.php @@ -181,7 +181,8 @@ if ( 'private' == $post->post_status ) {
ID ) { if ( 'future' == $post->post_status ) { // scheduled for publishing at a future date $stamp = __('Scheduled for: %1$s'); diff --git a/wp-admin/edit-pages.php b/wp-admin/edit-pages.php index fb7281cbd4..55321f44e1 100644 --- a/wp-admin/edit-pages.php +++ b/wp-admin/edit-pages.php @@ -290,7 +290,9 @@ if ( 1 == count($posts) && is_singular() ) : - + diff --git a/wp-admin/gears-manifest.php b/wp-admin/gears-manifest.php index 287379089d..43d41cf7c6 100644 --- a/wp-admin/gears-manifest.php +++ b/wp-admin/gears-manifest.php @@ -20,6 +20,12 @@ function __() {} */ function _c() {} +/** + * @ignore + */ +function _x() {} + + /** * @ignore */ diff --git a/wp-admin/includes/dashboard.php b/wp-admin/includes/dashboard.php index bae225cdda..13bd158085 100644 --- a/wp-admin/includes/dashboard.php +++ b/wp-admin/includes/dashboard.php @@ -526,7 +526,7 @@ function _wp_dashboard_recent_comments_row( &$comment, $show_date = true ) { $actions['edit'] = "". __('Edit') . ''; //$actions['quickedit'] = '' . __('Quick Edit') . ''; $actions['reply'] = '' . __('Reply') . ''; - $actions['spam'] = "" . _c( 'Spam|verb' ) . ''; + $actions['spam'] = "" . /* translators: mark as spam link */ _x( 'Spam', 'verb' ) . ''; $actions['delete'] = "" . __('Delete') . ''; $actions = apply_filters( 'comment_row_actions', $actions, $comment ); @@ -566,8 +566,8 @@ function _wp_dashboard_recent_comments_row( &$comment, $show_date = true ) { endswitch; $type = wp_specialchars( $type ); ?> - -

$type", $comment_post_link ); ?>

+ +

$type", $comment_post_link ); ?>

@@ -630,19 +630,22 @@ function wp_dashboard_incoming_links_output() { $content = wp_html_excerpt($content, 50) . ' ...'; if ( $link ) - $text = _c( '%1$s linked here saying, "%3$s"|feed_display' ); + /* translators: incoming links feed, %1$s is other person, %3$s is content */ + $text = __( '%1$s linked here saying, "%3$s"' ); else - $text = _c( '%1$s linked here saying, "%3$s"|feed_display' ); + /* translators: incoming links feed, %1$s is other person, %3$s is content */ + $text = __( '%1$s linked here saying, "%3$s"' ); if ( $show_date ) { if ( $show_author || $show_summary ) - $text .= _c( ' on %4$s|feed_display' ); + /* translators: incoming links feed, %4$s is the date */ + $text .= ' ' . __( 'on %4$s' ); $date = wp_specialchars( strip_tags( $item->get_date() ) ); $date = strtotime( $date ); $date = gmdate( get_option( 'date_format' ), $date ); } - echo "\t
  • " . sprintf( _c( "$text|feed_display" ), $publisher, $link, $content, $date ) . "
  • \n"; + echo "\t
  • " . sprintf( $text, $publisher, $link, $content, $date ) . "
  • \n"; } echo "\n"; diff --git a/wp-admin/includes/template.php b/wp-admin/includes/template.php index f4a7362ee9..4a285be09a 100644 --- a/wp-admin/includes/template.php +++ b/wp-admin/includes/template.php @@ -735,7 +735,8 @@ function tag_rows( $page = 1, $pagesize = 20, $searchterms = '', $taxonomy = 'po function wp_manage_posts_columns() { $posts_columns = array(); $posts_columns['cb'] = ''; - $posts_columns['title'] = _c('Post|noun'); + /* translators: manage posts column name */ + $posts_columns['title'] = _x('Post', 'column name'); $posts_columns['author'] = __('Author'); $posts_columns['categories'] = __('Categories'); $posts_columns['tags'] = __('Tags'); @@ -759,13 +760,16 @@ function wp_manage_media_columns() { $posts_columns = array(); $posts_columns['cb'] = ''; $posts_columns['icon'] = ''; - $posts_columns['media'] = _c('File|media column header'); + /* translators: column name */ + $posts_columns['media'] = _x('File', 'column name'); $posts_columns['author'] = __('Author'); //$posts_columns['tags'] = _c('Tags|media column header'); - $posts_columns['parent'] = _c('Attached to|media column header'); + /* translators: column name */ + $posts_columns['parent'] = _x('Attached to', 'column name'); $posts_columns['comments'] = '
    Comments
    '; //$posts_columns['comments'] = __('Comments'); - $posts_columns['date'] = _c('Date|media column header'); + /* translators: column name */ + $posts_columns['date'] = _x('Date', 'column name'); $posts_columns = apply_filters('manage_media_columns', $posts_columns); return $posts_columns; @@ -823,7 +827,8 @@ function get_column_headers($page) { $_wp_column_headers[$page] = array( 'cb' => '', 'author' => __('Author'), - 'comment' => _c('Comment|noun'), + /* translators: column name */ + 'comment' => _x('Comment', 'column name'), //'date' => __('Submitted'), 'response' => __('In Response To') ); @@ -1060,8 +1065,12 @@ function inline_edit_row( $type ) { - - + + + - - + + @@ -311,8 +311,8 @@ foreach ($arc_result as $arc_row) { - - + +
    + +