WordPress.org

Make WordPress Core

Changeset 14407


Ignore:
Timestamp:
05/03/2010 08:37:07 PM (11 years ago)
Author:
nbachiyski
Message:

Differentiate spam strings by subject: comments, sites, and users. Props dimadin. Fixes #13199

Location:
trunk/wp-admin
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/edit-comments.php

    r14374 r14407  
    317317<?php endif; ?>
    318318<?php if ( 'all' == $comment_status || 'approved' == $comment_status || 'moderated' == $comment_status ): ?>
    319 <option value="spam"><?php _e('Mark as Spam'); ?></option>
     319<option value="spam"><?php echo _x('Mark as Spam', 'comment'); ?></option>
    320320<?php endif; ?>
    321321<?php if ( 'trash' == $comment_status ): ?>
    322322<option value="untrash"><?php _e('Restore'); ?></option>
    323323<?php elseif ( 'spam' == $comment_status ): ?>
    324 <option value="unspam"><?php _e('Not Spam'); ?></option>
     324<option value="unspam"><?php echo _x('Not Spam', 'comment'); ?></option>
    325325<?php endif; ?>
    326326<?php if ( 'trash' == $comment_status || 'spam' == $comment_status || !EMPTY_TRASH_DAYS ): ?>
     
    414414<?php endif; ?>
    415415<?php if ( 'all' == $comment_status || 'approved' == $comment_status || 'moderated' == $comment_status ): ?>
    416 <option value="spam"><?php _e('Mark as Spam'); ?></option>
     416<option value="spam"><?php echo _x('Mark as Spam', 'comment'); ?></option>
    417417<?php endif; ?>
    418418<?php if ( 'trash' == $comment_status ): ?>
     
    422422<option value="delete"><?php _e('Delete Permanently'); ?></option>
    423423<?php elseif ( 'spam' == $comment_status ): ?>
    424 <option value="unspam"><?php _e('Not Spam'); ?></option>
     424<option value="unspam"><?php echo _x('Not Spam', 'comment'); ?></option>
    425425<?php else: ?>
    426426<option value="trash"><?php _e('Move to Trash'); ?></option>
  • trunk/wp-admin/includes/dashboard.php

    r14374 r14407  
    329329    // Spam Comments
    330330    $num = number_format_i18n($num_comm->spam);
    331     $text = _n( 'Spam', 'Spam', $num_comm->spam );
     331    $text = _nx( 'Spam', 'Spam', $num_comm->spam, 'comment' );
    332332    if ( current_user_can( 'moderate_comments' ) ) {
    333333        $num = "<a href='edit-comments.php?comment_status=spam'><span class='spam-count'>$num</span></a>";
  • trunk/wp-admin/includes/template.php

    r14404 r14407  
    21112111                        $actions['spam'] = "<a href='$spam_url' class='delete:the-comment-list:comment-$comment->comment_ID::spam=1 vim-s vim-destructive' title='" . esc_attr__( 'Mark this comment as spam' ) . "'>" . /* translators: mark as spam link */ _x( 'Spam', 'verb' ) . '</a>';
    21122112                    } elseif ( 'spam' == $the_comment_status ) {
    2113                         $actions['unspam'] = "<a href='$unspam_url' class='delete:the-comment-list:comment-$comment->comment_ID:66cc66:unspam=1 vim-z vim-destructive'>" . __( 'Not Spam' ) . '</a>';
     2113                        $actions['unspam'] = "<a href='$unspam_url' class='delete:the-comment-list:comment-$comment->comment_ID:66cc66:unspam=1 vim-z vim-destructive'>" . _x( 'Not Spam', 'comment' ) . '</a>';
    21142114                    } elseif ( 'trash' == $the_comment_status ) {
    21152115                        $actions['untrash'] = "<a href='$untrash_url' class='delete:the-comment-list:comment-$comment->comment_ID:66cc66:untrash=1 vim-z vim-destructive'>" . __( 'Restore' ) . '</a>';
  • trunk/wp-admin/ms-sites.php

    r14374 r14407  
    114114                        </tr>
    115115                        <tr class="form-field">
    116                             <th scope="row"><?php _e( 'Registered') ?></th>
     116                            <th scope="row"><?php echo _x( 'Registered', 'site' ) ?></th>
    117117                            <td><input name="blog[registered]" type="text" id="blog_registered" value="<?php echo esc_attr( $details->registered ) ?>" size="40" /></td>
    118118                        </tr>
     
    125125                        if ( ! $is_main_site ) {
    126126                            $radio_fields['archived'] = __( 'Archived' );
    127                             $radio_fields['spam']     = __( 'Spam' );
     127                            $radio_fields['spam']     = _x( 'Spam', 'site' );
    128128                            $radio_fields['deleted']  = __( 'Deleted' );
    129129                        }
     
    415415                <option value="-1" selected="selected"><?php _e( 'Bulk Actions' ); ?></option>
    416416                <option value="delete"><?php _e( 'Delete' ); ?></option>
    417                 <option value="spam"><?php _e( 'Mark as Spam' ); ?></option>
    418                 <option value="notspam"><?php _e( 'Not Spam' ); ?></option>
     417                <option value="spam"><?php echo _x( 'Mark as Spam', 'site' ); ?></option>
     418                <option value="notspam"><?php echo _x( 'Not Spam', 'site' ); ?></option>
    419419            </select>
    420420            <input type="submit" value="<?php esc_attr_e( 'Apply' ); ?>" name="doaction" id="doaction" class="button-secondary action" />
     
    449449            'blogname'     => $blogname_columns,
    450450            'lastupdated'  => __( 'Last Updated'),
    451             'registered'   => __( 'Registered' ),
     451            'registered'   => _x( 'Registered', 'site' ),
    452452            'users'        => __( 'Users' )
    453453        );
     
    490490            <tbody id="the-site-list" class="list:site">
    491491            <?php
    492             $status_list = array( 'archived' => array( 'site-archived', __( 'Archived' ) ), 'spam' => array( 'site-spammed', __( 'Spam' ) ), 'deleted' => array( 'site-deleted', __( 'Deleted' ) ), 'mature' => array( 'site-mature', __( 'Mature' ) ) );
     492            $status_list = array( 'archived' => array( 'site-archived', __( 'Archived' ) ), 'spam' => array( 'site-spammed', _x( 'Spam', 'site' ) ), 'deleted' => array( 'site-deleted', __( 'Deleted' ) ), 'mature' => array( 'site-mature', __( 'Mature' ) ) );
    493493            if ( $blog_list ) {
    494494                $class = '';
     
    535535                                    <?php
    536536                                    if ( 'list' != $mode )
    537                                         echo '<p>' . sprintf( _x( '%1$s &#8211; <em>%2$s', '%1$s: site name. %2$s: site tagline.' ), get_blog_option( $blog['blog_id'], 'blogname' ), get_blog_option( $blog['blog_id'], 'blogdescription ' ) ) . '</em></p>';
     537                                        echo '<p>' . sprintf( _x( '%1$s &#8211; <em>%2$s</em>', '%1$s: site name. %2$s: site tagline.' ), get_blog_option( $blog['blog_id'], 'blogname' ), get_blog_option( $blog['blog_id'], 'blogdescription ' ) ) . '</p>';
    538538
    539539                                    // Preordered.
     
    558558                                            $actions['unarchive']   = '<span class="archive"><a href="' . esc_url( admin_url( 'ms-edit.php?action=confirm&amp;action2=unarchiveblog&amp;id=' .  $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( 'You are about to unarchive the site %s.' ), $blogname ) ) ) ) . '">' . __( 'Unarchive' ) . '</a></span>';
    559559                                        else
    560                                             $actions['archive'] = '<span class="archive"><a href="' . esc_url( admin_url( 'ms-edit.php?action=confirm&amp;action2=archiveblog&amp;id=' . $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( 'You are about to archive the site %s.' ), $blogname ) ) ) ) . '">' . __( 'Archive' ) . '</a></span>';
     560                                            $actions['archive'] = '<span class="archive"><a href="' . esc_url( admin_url( 'ms-edit.php?action=confirm&amp;action2=archiveblog&amp;id=' . $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( 'You are about to archive the site %s.' ), $blogname ) ) ) ) . '">' . _x( 'Archive', 'verb; site' ) . '</a></span>';
    561561
    562562                                        if ( get_blog_status( $blog['blog_id'], 'spam' ) == '1' )
    563                                             $actions['unspam']  = '<span class="spam"><a href="' . esc_url( admin_url( 'ms-edit.php?action=confirm&amp;action2=unspamblog&amp;id=' . $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( 'You are about to unspam the site %s.' ), $blogname ) ) ) ) . '">' . __( 'Not Spam' ) . '</a></span>';
     563                                            $actions['unspam']  = '<span class="spam"><a href="' . esc_url( admin_url( 'ms-edit.php?action=confirm&amp;action2=unspamblog&amp;id=' . $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( 'You are about to unspam the site %s.' ), $blogname ) ) ) ) . '">' . _x( 'Not Spam', 'site' ) . '</a></span>';
    564564                                        else
    565                                             $actions['spam']    = '<span class="spam"><a href="' . esc_url( admin_url( 'ms-edit.php?action=confirm&amp;action2=spamblog&amp;id=' . $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( 'You are about to mark the site %s as spam.' ), $blogname ) ) ) ) . '">' . __( 'Spam' ) . '</a></span>';
     565                                            $actions['spam']    = '<span class="spam"><a href="' . esc_url( admin_url( 'ms-edit.php?action=confirm&amp;action2=spamblog&amp;id=' . $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( 'You are about to mark the site %s as spam.' ), $blogname ) ) ) ) . '">' . _x( 'Spam', 'site' ) . '</a></span>';
    566566
    567567                                        $actions['delete']  = '<span class="delete"><a href="' . esc_url( admin_url( 'ms-edit.php?action=confirm&amp;action2=deleteblog&amp;id=' . $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( 'You are about to delete the site %s.' ), $blogname ) ) ) ) . '">' . __( 'Delete' ) . '</a></span>';
     
    666666                <option value="-1" selected="selected"><?php _e( 'Bulk Actions' ); ?></option>
    667667                <option value="delete"><?php _e( 'Delete' ); ?></option>
    668                 <option value="spam"><?php _e( 'Mark as Spam' ); ?></option>
    669                 <option value="notspam"><?php _e( 'Not Spam' ); ?></option>
     668                <option value="spam"><?php echo _x( 'Mark as Spam', 'site' ); ?></option>
     669                <option value="notspam"><?php echo _x( 'Not Spam', 'site' ); ?></option>
    670670            </select>
    671671            <input type="submit" value="<?php esc_attr_e( 'Apply' ); ?>" name="doaction2" id="doaction2" class="button-secondary action" />
  • trunk/wp-admin/ms-users.php

    r14404 r14407  
    131131                    <option value="-1" selected="selected"><?php _e( 'Bulk Actions' ); ?></option>
    132132                    <option value="delete"><?php _e( 'Delete' ); ?></option>
    133                     <option value="spam"><?php _e( 'Mark as Spam' ); ?></option>
    134                     <option value="notspam"><?php _e( 'Not Spam' ); ?></option>
     133                    <option value="spam"><?php echo _x( 'Mark as Spam', 'user' ); ?></option>
     134                    <option value="notspam"><?php echo _x( 'Not Spam', 'user' ); ?></option>
    135135                </select>
    136136                <input type="submit" value="<?php esc_attr_e( 'Apply' ); ?>" name="doaction" id="doaction" class="button-secondary action" />
     
    163163            'name'       => __( 'Name' ),
    164164            'email'      => __( 'E-mail' ),
    165             'registered' => __( 'Registered' ),
     165            'registered' => _x( 'Registered', 'user' ),
    166166            'blogs'      => __( 'Sites' )
    167167        );
     
    325325                    <option value="-1" selected="selected"><?php _e( 'Bulk Actions' ); ?></option>
    326326                    <option value="delete"><?php _e( 'Delete' ); ?></option>
    327                     <option value="spam"><?php _e( 'Mark as Spam' ); ?></option>
    328                     <option value="notspam"><?php _e( 'Not Spam' ); ?></option>
     327                    <option value="spam"><?php echo _x( 'Mark as Spam', 'user' ); ?></option>
     328                    <option value="notspam"><?php echo _x( 'Not Spam', 'user' ); ?></option>
    329329                </select>
    330330                <input type="submit" value="<?php esc_attr_e( 'Apply' ); ?>" name="doaction2" id="doaction2" class="button-secondary action" />
Note: See TracChangeset for help on using the changeset viewer.