mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-23 01:27:36 +01:00
i18n fixes, logic cleanup, wording clarifications, and more from nbachiyski. fixes #3474
git-svn-id: http://svn.automattic.com/wordpress/trunk@4658 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
bdd210972c
commit
8a678f3841
@ -40,10 +40,10 @@ function wp_write_post() {
|
|||||||
if ( $_POST['post_author'] != $_POST['user_ID'] ) {
|
if ( $_POST['post_author'] != $_POST['user_ID'] ) {
|
||||||
if ( 'page' == $_POST['post_type'] ) {
|
if ( 'page' == $_POST['post_type'] ) {
|
||||||
if ( !current_user_can( 'edit_others_pages' ) )
|
if ( !current_user_can( 'edit_others_pages' ) )
|
||||||
return new WP_Error( 'edit_others_pages', __( 'You cannot create pages as this user.' ) );
|
return new WP_Error( 'edit_others_pages', __( 'You are not allowed to create pages as this user.' ) );
|
||||||
} else {
|
} else {
|
||||||
if ( !current_user_can( 'edit_others_posts' ) )
|
if ( !current_user_can( 'edit_others_posts' ) )
|
||||||
return new WP_Error( 'edit_others_posts', __( 'You cannot post as this user.' ) );
|
return new WP_Error( 'edit_others_posts', __( 'You are not allowed to post as this user.' ) );
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -184,10 +184,10 @@ function edit_post() {
|
|||||||
if ( $_POST['post_author'] != $_POST['user_ID'] ) {
|
if ( $_POST['post_author'] != $_POST['user_ID'] ) {
|
||||||
if ( 'page' == $_POST['post_type'] ) {
|
if ( 'page' == $_POST['post_type'] ) {
|
||||||
if ( !current_user_can( 'edit_others_pages' ) )
|
if ( !current_user_can( 'edit_others_pages' ) )
|
||||||
wp_die( __('You cannot edit pages as this user.' ));
|
wp_die( __('You are not allowed to edit pages as this user.' ));
|
||||||
} else {
|
} else {
|
||||||
if ( !current_user_can( 'edit_others_posts' ) )
|
if ( !current_user_can( 'edit_others_posts' ) )
|
||||||
wp_die( __('You cannot edit posts as this user.' ));
|
wp_die( __('You are not allowed to edit posts as this user.' ));
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -561,7 +561,7 @@ function add_link() {
|
|||||||
|
|
||||||
function edit_link( $link_id = '' ) {
|
function edit_link( $link_id = '' ) {
|
||||||
if (!current_user_can( 'manage_links' ))
|
if (!current_user_can( 'manage_links' ))
|
||||||
wp_die( __("Cheatin' uh ?" ));
|
wp_die( __( 'Cheatin&8217; uh?' ));
|
||||||
|
|
||||||
$_POST['link_url'] = wp_specialchars( $_POST['link_url'] );
|
$_POST['link_url'] = wp_specialchars( $_POST['link_url'] );
|
||||||
$_POST['link_url'] = preg_match('/^(https?|ftps?|mailto|news|irc|gopher|nntp|feed|telnet):/is', $_POST['link_url']) ? $_POST['link_url'] : 'http://' . $_POST['link_url'];
|
$_POST['link_url'] = preg_match('/^(https?|ftps?|mailto|news|irc|gopher|nntp|feed|telnet):/is', $_POST['link_url']) ? $_POST['link_url'] : 'http://' . $_POST['link_url'];
|
||||||
@ -826,7 +826,7 @@ function user_row( $user_object, $style = '' ) {
|
|||||||
$r .= "\n\t\t<td align='center'>";
|
$r .= "\n\t\t<td align='center'>";
|
||||||
if ( $numposts > 0 ) {
|
if ( $numposts > 0 ) {
|
||||||
$r .= "<a href='edit.php?author=$user_object->ID' title='" . __( 'View posts by this author' ) . "' class='edit'>";
|
$r .= "<a href='edit.php?author=$user_object->ID' title='" . __( 'View posts by this author' ) . "' class='edit'>";
|
||||||
$r .= sprintf( __('View %1$s %2$s' ), $numposts, __ngettext( 'post', 'posts', $numposts ));
|
$r .= sprintf(__ngettext( 'View %s post', 'View %s posts', $numposts ), $numposts);
|
||||||
$r .= '</a>';
|
$r .= '</a>';
|
||||||
}
|
}
|
||||||
$r .= "</td>\n\t\t<td>";
|
$r .= "</td>\n\t\t<td>";
|
||||||
@ -1069,9 +1069,7 @@ function touch_time( $edit = 1, $for_post = 1 ) {
|
|||||||
<input type="hidden" id="ss" name="ss" value="<?php echo $ss ?>" size="2" maxlength="2" onchange="edit_date.checked=true" />
|
<input type="hidden" id="ss" name="ss" value="<?php echo $ss ?>" size="2" maxlength="2" onchange="edit_date.checked=true" />
|
||||||
<?php
|
<?php
|
||||||
if ( $edit ) {
|
if ( $edit ) {
|
||||||
_e( 'Existing timestamp' );
|
printf( __('Existing timestamp: %1$s %2$s, %3$s @ %4$s:%5$s' ), $wp_locale->get_month( $mm ), $jj, $aa, $hh, $mn );
|
||||||
//echo ': ' . $wp_locale->get_month( $mm ) . "$jj, $aa @ $hh:$mn";
|
|
||||||
echo sprintf( __(': %1$s %2$s, %3$s @ %4$s:%5$s' ), $wp_locale->get_month( $mm ), $jj, $aa, $hh, $mn );
|
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
@ -34,10 +34,10 @@ case 'delete':
|
|||||||
|
|
||||||
// Don't delete the default cats.
|
// Don't delete the default cats.
|
||||||
if ( $cat_ID == get_option('default_category') )
|
if ( $cat_ID == get_option('default_category') )
|
||||||
wp_die(sprintf(__("Can't delete the <strong>%s</strong> category: this is the default one"), $cat_name));
|
wp_die(sprintf(__("Can&8217;t delete the <strong>%s</strong> category: this is the default one"), $cat_name));
|
||||||
|
|
||||||
if ( $cat_ID == get_option('default_link_category') )
|
if ( $cat_ID == get_option('default_link_category') )
|
||||||
wp_die(sprintf(__("Can't delete the <strong>%s</strong> category: this is the default one for links"), $cat_name));
|
wp_die(sprintf(__("Can&8217;t delete the <strong>%s</strong> category: this is the default one for links"), $cat_name));
|
||||||
|
|
||||||
wp_delete_category($cat_ID);
|
wp_delete_category($cat_ID);
|
||||||
|
|
||||||
|
@ -67,10 +67,11 @@ if ( !empty( $_POST['delete_comments'] ) ) :
|
|||||||
}
|
}
|
||||||
endforeach;
|
endforeach;
|
||||||
echo '<div style="background-color: rgb(207, 235, 247);" id="message" class="updated fade"><p>';
|
echo '<div style="background-color: rgb(207, 235, 247);" id="message" class="updated fade"><p>';
|
||||||
if ( !empty( $_POST['spam_button'] ) )
|
if ( !empty( $_POST['spam_button'] ) ) {
|
||||||
printf(__('%s comments marked as spam.'), $i);
|
printf(__ngettext('%s comment marked as spam', '%s comments marked as spam.', $i), $i);
|
||||||
else
|
} else {
|
||||||
printf(__('%s comments deleted.'), $i);
|
printf(__ngettext('%s comment deleted.', '%s comments deleted.', $i), $i);
|
||||||
|
}
|
||||||
echo '</p></div>';
|
echo '</p></div>';
|
||||||
endif;
|
endif;
|
||||||
|
|
||||||
|
@ -206,7 +206,7 @@ if (current_user_can('upload_files')) {
|
|||||||
<h3 class="dbx-handle"><?php _e('Trackbacks') ?></h3>
|
<h3 class="dbx-handle"><?php _e('Trackbacks') ?></h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="dbx-c-ontent-wrapper">
|
<div class="dbx-c-ontent-wrapper">
|
||||||
<div class="dbx-content"><?php _e('Send trackbacks to'); ?>: <?php echo $form_trackback; ?> (<?php _e('Separate multiple URIs with spaces'); ?>)
|
<div class="dbx-content"><?php _e('Send trackbacks to:'); ?> <?php echo $form_trackback; ?> (<?php _e('Separate multiple URLs with spaces'); ?>)
|
||||||
<?php
|
<?php
|
||||||
if ( ! empty($pings) )
|
if ( ! empty($pings) )
|
||||||
echo $pings;
|
echo $pings;
|
||||||
|
@ -67,7 +67,7 @@ addLoadEvent(focusit);
|
|||||||
|
|
||||||
<tr>
|
<tr>
|
||||||
<th scope="row" valign="top"><?php _e('Delete'); $delete_nonce = wp_create_nonce( 'delete-comment_' . $comment->comment_ID ); ?>:</th>
|
<th scope="row" valign="top"><?php _e('Delete'); $delete_nonce = wp_create_nonce( 'delete-comment_' . $comment->comment_ID ); ?>:</th>
|
||||||
<td><input name="deletecomment" class="button delete" type="submit" id="deletecomment" tabindex="10" value="<?php _e('Delete this comment') ?>" <?php echo "onclick=\"if ( confirm('" . __("You are about to delete this comment \\n \'Cancel\' to stop, \'OK\' to delete.") . "') ) { document.forms.post._wpnonce.value = '$delete_nonce'; return true; } return false;\""; ?> />
|
<td><input name="deletecomment" class="button delete" type="submit" id="deletecomment" tabindex="10" value="<?php _e('Delete this comment') ?>" <?php echo "onclick=\"if ( confirm('" . js_escape(__("You are about to delete this comment. \n 'Cancel' to stop, 'OK' to delete.")) . "') ) { document.forms.post._wpnonce.value = '$delete_nonce'; return true; } return false;\""; ?> />
|
||||||
<input type="hidden" name="c" value="<?php echo $comment->comment_ID ?>" />
|
<input type="hidden" name="c" value="<?php echo $comment->comment_ID ?>" />
|
||||||
<input type="hidden" name="p" value="<?php echo $comment->comment_post_ID ?>" />
|
<input type="hidden" name="p" value="<?php echo $comment->comment_post_ID ?>" />
|
||||||
<input type="hidden" name="noredir" value="1" />
|
<input type="hidden" name="noredir" value="1" />
|
||||||
|
@ -51,7 +51,7 @@ edCanvas = document.getElementById('content');
|
|||||||
|
|
||||||
<input type="hidden" name="post_pingback" value="<?php echo get_option('default_pingback_flag') ?>" id="post_pingback" />
|
<input type="hidden" name="post_pingback" value="<?php echo get_option('default_pingback_flag') ?>" id="post_pingback" />
|
||||||
|
|
||||||
<p><label for="trackback"> <?php printf(__('<a href="%s" title="Help on trackbacks"><strong>TrackBack</strong> a <abbr title="Universal Resource Locator">URL</abbr></a>:</label> (Separate multiple <abbr title="Universal Resource Locator">URL</abbr>s with spaces.)<br />'), 'http://wordpress.org/docs/reference/post/#trackback') ?>
|
<p><label for="trackback"> <?php printf(__('<a href="%s" title="Help on trackbacks"><strong>TrackBack</strong> a <abbr title="Universal Resource Locator">URL</abbr></a>:</label> (Separate multiple <abbr title="Universal Resource Locator">URL</abbr>s with spaces.)'), 'http://wordpress.org/docs/reference/post/#trackback'); echo '<br />'; ?>
|
||||||
<input type="text" name="trackback_url" style="width: 360px" id="trackback" tabindex="7" /></p>
|
<input type="text" name="trackback_url" style="width: 360px" id="trackback" tabindex="7" /></p>
|
||||||
|
|
||||||
<p class="submit"><input name="saveasdraft" type="submit" id="saveasdraft" tabindex="9" value="<?php _e('Save as Draft') ?>" />
|
<p class="submit"><input name="saveasdraft" type="submit" id="saveasdraft" tabindex="9" value="<?php _e('Save as Draft') ?>" />
|
||||||
|
@ -82,7 +82,7 @@ addLoadEvent(focusit);
|
|||||||
|
|
||||||
<?php if ( 0 != count( get_page_templates() ) ) { ?>
|
<?php if ( 0 != count( get_page_templates() ) ) { ?>
|
||||||
<fieldset id="pagetemplate" class="dbx-box">
|
<fieldset id="pagetemplate" class="dbx-box">
|
||||||
<h3 class="dbx-handle"><?php _e('Page Template:') ?></h3>
|
<h3 class="dbx-handle"><?php _e('Page Template') ?></h3>
|
||||||
<div class="dbx-content"><p><select name="page_template">
|
<div class="dbx-content"><p><select name="page_template">
|
||||||
<option value='default'><?php _e('Default Template'); ?></option>
|
<option value='default'><?php _e('Default Template'); ?></option>
|
||||||
<?php page_template_dropdown($post->page_template); ?>
|
<?php page_template_dropdown($post->page_template); ?>
|
||||||
|
@ -221,7 +221,7 @@ foreach($posts_columns as $column_name=>$column_display_name) {
|
|||||||
|
|
||||||
case 'control_delete':
|
case 'control_delete':
|
||||||
?>
|
?>
|
||||||
<td><?php if ( current_user_can('delete_post',$post->ID) ) { echo "<a href='" . wp_nonce_url("post.php?action=delete&post=$id", 'delete-post_' . $post->ID) . "' class='delete' onclick=\"return deleteSomething( 'post', " . $id . ", '" . sprintf(__("You are about to delete this post "%s".\\n"OK" to delete, "Cancel" to stop."), js_escape(get_the_title()) ) . "' );\">" . __('Delete') . "</a>"; } ?></td>
|
<td><?php if ( current_user_can('delete_post',$post->ID) ) { echo "<a href='" . wp_nonce_url("post.php?action=delete&post=$id", 'delete-post_' . $post->ID) . "' class='delete' onclick=\"return deleteSomething( 'post', " . $id . ", '" . js_escape(sprintf(__("You are about to delete this post '%s'.\n'OK' to delete, 'Cancel' to stop."), get_the_title())) . "' );\">" . __('Delete') . "</a>"; } ?></td>
|
||||||
<?php
|
<?php
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@ -283,12 +283,12 @@ foreach ($comments as $comment) {
|
|||||||
<?php
|
<?php
|
||||||
if ( current_user_can('edit_post', $comment->comment_post_ID) ) {
|
if ( current_user_can('edit_post', $comment->comment_post_ID) ) {
|
||||||
echo " <a href='comment.php?action=editcomment&c=".$comment->comment_ID."'>" . __('Edit') . '</a>';
|
echo " <a href='comment.php?action=editcomment&c=".$comment->comment_ID."'>" . __('Edit') . '</a>';
|
||||||
echo ' | <a href="' . wp_nonce_url('comment.php?action=deletecomment&p=' . $post->ID . '&c=' . $comment->comment_ID, 'delete-comment_' . $comment->comment_ID) . '" onclick="return deleteSomething( \'comment\', ' . $comment->comment_ID . ', \'' . sprintf(__("You are about to delete this comment by "%s".\\n"Cancel" to stop, "OK" to delete."), js_escape($comment->comment_author)) . "', theCommentList );\">" . __('Delete') . '</a> ';
|
echo ' | <a href="' . wp_nonce_url('comment.php?action=deletecomment&p=' . $post->ID . '&c=' . $comment->comment_ID, 'delete-comment_' . $comment->comment_ID) . '" onclick="return deleteSomething( \'comment\', ' . $comment->comment_ID . ', \'' . sprintf(__("You are about to delete this comment by '%s'.\n'Cancel' to stop, 'OK' to delete."), js_escape($comment->comment_author)) . "', theCommentList );\">" . __('Delete') . '</a> ';
|
||||||
if ( ('none' != $comment_status) && ( current_user_can('moderate_comments') ) ) {
|
if ( ('none' != $comment_status) && ( current_user_can('moderate_comments') ) ) {
|
||||||
echo '<span class="unapprove"> | <a href="' . wp_nonce_url('comment.php?action=unapprovecomment&p=' . $post->ID . '&c=' . $comment->comment_ID, 'unapprove-comment_' . $comment->comment_ID) . '" onclick="return dimSomething( \'comment\', ' . $comment->comment_ID . ', \'unapproved\', theCommentList );">' . __('Unapprove') . '</a> </span>';
|
echo '<span class="unapprove"> | <a href="' . wp_nonce_url('comment.php?action=unapprovecomment&p=' . $post->ID . '&c=' . $comment->comment_ID, 'unapprove-comment_' . $comment->comment_ID) . '" onclick="return dimSomething( \'comment\', ' . $comment->comment_ID . ', \'unapproved\', theCommentList );">' . __('Unapprove') . '</a> </span>';
|
||||||
echo '<span class="approve"> | <a href="' . wp_nonce_url('comment.php?action=approvecomment&p=' . $post->ID . '&c=' . $comment->comment_ID, 'approve-comment_' . $comment->comment_ID) . '" onclick="return dimSomething( \'comment\', ' . $comment->comment_ID . ', \'unapproved\', theCommentList );">' . __('Approve') . '</a> </span>';
|
echo '<span class="approve"> | <a href="' . wp_nonce_url('comment.php?action=approvecomment&p=' . $post->ID . '&c=' . $comment->comment_ID, 'approve-comment_' . $comment->comment_ID) . '" onclick="return dimSomething( \'comment\', ' . $comment->comment_ID . ', \'unapproved\', theCommentList );">' . __('Approve') . '</a> </span>';
|
||||||
}
|
}
|
||||||
echo " | <a href=\"" . wp_nonce_url("comment.php?action=deletecomment&dt=spam&p=".$comment->comment_post_ID."&c=".$comment->comment_ID, 'delete-comment_' . $comment->comment_ID) . "\" onclick=\"return deleteSomething( 'comment-as-spam', $comment->comment_ID, '" . sprintf(__("You are about to mark as spam this comment by "%s".\\n"Cancel" to stop, "OK" to mark as spam."), js_escape( $comment->comment_author)) . "', theCommentList );\">" . __('Spam') . "</a> ]";
|
echo " | <a href=\"" . wp_nonce_url("comment.php?action=deletecomment&dt=spam&p=".$comment->comment_post_ID."&c=".$comment->comment_ID, 'delete-comment_' . $comment->comment_ID) . "\" onclick=\"return deleteSomething( 'comment-as-spam', $comment->comment_ID, '" . sprintf(__("You are about to mark as spam this comment by '%s'.\n'Cancel' to stop, 'OK' to mark as spam."), js_escape( $comment->comment_author)) . "', theCommentList );\">" . __('Spam') . "</a> ]";
|
||||||
} // end if any comments to show
|
} // end if any comments to show
|
||||||
?>
|
?>
|
||||||
</p>
|
</p>
|
||||||
|
@ -14,7 +14,7 @@ require_once ('admin-header.php');
|
|||||||
<div class="narrow">
|
<div class="narrow">
|
||||||
<p><?php _e('When you click the button below WordPress will create an XML file for you to save to your computer.'); ?></p>
|
<p><?php _e('When you click the button below WordPress will create an XML file for you to save to your computer.'); ?></p>
|
||||||
<p><?php _e('This format, which we call WordPress eXtended RSS or WXR, will contain your posts, comments, custom fields, and categories.'); ?></p>
|
<p><?php _e('This format, which we call WordPress eXtended RSS or WXR, will contain your posts, comments, custom fields, and categories.'); ?></p>
|
||||||
<p><?php _e('Once you\'ve saved the download file, you can use the Import function on another WordPress blog to import this blog.'); ?></p>
|
<p><?php _e('Once you&8217;ve saved the download file, you can use the Import function on another WordPress blog to import this blog.'); ?></p>
|
||||||
<form action="" method="get">
|
<form action="" method="get">
|
||||||
<h3><?php _e('Optional options'); ?></h3>
|
<h3><?php _e('Optional options'); ?></h3>
|
||||||
|
|
||||||
|
@ -107,7 +107,12 @@ if (0 < $numcomms) $numcomms = number_format($numcomms);
|
|||||||
$numcats = $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->categories");
|
$numcats = $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->categories");
|
||||||
if (0 < $numcats) $numcats = number_format($numcats);
|
if (0 < $numcats) $numcats = number_format($numcats);
|
||||||
?>
|
?>
|
||||||
<p><?php printf(__('There are currently %1$s <a href="%2$s" title="Posts">posts</a> and %3$s <a href="%4$s" title="Comments">comments</a>, contained within %5$s <a href="%6$s" title="categories">categories</a>.'), $numposts, 'edit.php', $numcomms, 'edit-comments.php', $numcats, 'categories.php'); ?></p>
|
<p><?php
|
||||||
|
$post_str = sprintf(__ngettext('%1$s <a href="%2$s" title="Posts">post</a>', '%1$s <a href="%2$s" title="Posts">posts</a>', $numposts), $numposts, 'edit.php');
|
||||||
|
$comm_str = sprintf(__ngettext('%1$s <a href="%2$s" title="Comments">comment</a>', '%1$s <a href="%2$s" title="Comments">comments</a>', $numcomms), $numcomms, 'edit-comments.php');
|
||||||
|
$cat_str = sprintf(__ngettext('%1$s <a href="%2$s" title="Categories">category</a>', '%1$s <a href="%2$s" title="Categories">categories</a>', $numcats), $numcats, 'categories.php');
|
||||||
|
|
||||||
|
printf(__('There are currently %1$s and %2$s, contained within %3$s.'), $post_str, $comm_str, $cat_str); ?></p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<?php do_action('activity_box_end'); ?>
|
<?php do_action('activity_box_end'); ?>
|
||||||
|
@ -28,7 +28,7 @@ require('admin-header.php');
|
|||||||
|
|
||||||
<div id="wp-link-bookmarklet" class="wrap">
|
<div id="wp-link-bookmarklet" class="wrap">
|
||||||
<h3><?php _e('Add Link Bookmarklet'); ?></h3>
|
<h3><?php _e('Add Link Bookmarklet'); ?></h3>
|
||||||
<p><?php _e('Right click on the following link and choose "Bookmark This Link..." to create an add link shortcut. Right now this only works on Mozilla or Netscape, but we’re working on it.'); ?></p>
|
<p><?php _e('Right click on the following link and choose "Bookmark This Link..." to create an add link shortcut. Right now this only works on Mozilla or Netscape, but we&8217;re working on it.'); ?></p>
|
||||||
<?php printf('<p><a href="%s" title="'.__('Link add bookmarklet').'">'.__('Link This').'</a></p>', "javascript:void(linkmanpopup=window.open('" . get_option('siteurl') . "/wp-admin/link-add.php?action=popup&linkurl='+escape(location.href)+'&name='+escape(document.title),'LinkManager','scrollbars=yes,width=750,height=550,left=15,top=15,status=yes,resizable=yes'));linkmanpopup.focus();window.focus();linkmanpopup.focus();") ?>
|
<?php printf('<p><a href="%s" title="'.__('Link add bookmarklet').'">'.__('Link This').'</a></p>', "javascript:void(linkmanpopup=window.open('" . get_option('siteurl') . "/wp-admin/link-add.php?action=popup&linkurl='+escape(location.href)+'&name='+escape(document.title),'LinkManager','scrollbars=yes,width=750,height=550,left=15,top=15,status=yes,resizable=yes'));linkmanpopup.focus();window.focus();linkmanpopup.focus();") ?>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -65,7 +65,7 @@ function checkAll(form)
|
|||||||
if ( isset($_GET['deleted']) ) {
|
if ( isset($_GET['deleted']) ) {
|
||||||
echo '<div style="background-color: rgb(207, 235, 247);" id="message" class="updated fade"><p>';
|
echo '<div style="background-color: rgb(207, 235, 247);" id="message" class="updated fade"><p>';
|
||||||
$deleted = (int) $_GET['deleted'];
|
$deleted = (int) $_GET['deleted'];
|
||||||
printf(__('%s links deleted.'), $deleted);
|
printf(__ngettext('%s link deleted.', '%s links deleted', $deleted), $deleted);
|
||||||
echo '</p></div>';
|
echo '</p></div>';
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
|
@ -72,32 +72,20 @@ if ( isset($_GET['deleted']) || isset($_GET['approved']) || isset($_GET['ignored
|
|||||||
$ignored = (int) $_GET['ignored'];
|
$ignored = (int) $_GET['ignored'];
|
||||||
$spam = (int) $_GET['spam'];
|
$spam = (int) $_GET['spam'];
|
||||||
if ($approved) {
|
if ($approved) {
|
||||||
if ('1' == $approved) {
|
printf(__ngettext('%s comment approved', '%s comments approved', $approved), $approved);
|
||||||
echo __("1 comment approved") . " <br/>\n";
|
echo "<br/>\n";
|
||||||
} else {
|
|
||||||
echo sprintf(__("%s comments approved <br />"), $approved) . "\n";
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if ($deleted) {
|
if ($deleted) {
|
||||||
if ('1' == $deleted) {
|
printf(__ngettext('%s comment deleted', '%s comments deleted', $deleted), $deleted);
|
||||||
echo __("1 comment deleted") . " <br/>\n";
|
echo "<br/>\n";
|
||||||
} else {
|
|
||||||
echo sprintf(__("%s comments deleted"), $deleted) . " <br/>\n";
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if ($spam) {
|
if ($spam) {
|
||||||
if ('1' == $spam) {
|
printf(__ngettext('%s comment marked as spam', '%s comments marked as spam', $spam), $spam);
|
||||||
echo __("1 comment marked as spam") . " <br/>\n";
|
echo "<br/>\n";
|
||||||
} else {
|
|
||||||
echo sprintf(__("%s comments marked as spam"), $spam) . " <br/>\n";
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if ($ignored) {
|
if ($ignored) {
|
||||||
if ('1' == $ignored) {
|
printf(__ngettext('%s comment unchanged', '%s comments unchanged', $ignored), $ignored);
|
||||||
echo __("1 comment unchanged") . " <br/>\n";
|
echo "<br/>\n";
|
||||||
} else {
|
|
||||||
echo sprintf(__("%s comments unchanged"), $ignored) . " <br/>\n";
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
echo "</p></div>\n";
|
echo "</p></div>\n";
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,7 @@ include('admin-header.php');
|
|||||||
<?php wp_nonce_field('update-options') ?>
|
<?php wp_nonce_field('update-options') ?>
|
||||||
<p class="submit"><input type="submit" name="Submit" value="<?php _e('Update Options »') ?>" /></p>
|
<p class="submit"><input type="submit" name="Submit" value="<?php _e('Update Options »') ?>" /></p>
|
||||||
<fieldset class="options">
|
<fieldset class="options">
|
||||||
<legend><?php _e('Usual settings for an article:<br /><small><em>(These settings may be overridden for individual articles.)</em></small>') ?></legend>
|
<legend><?php echo __('Usual settings for an article:').'<br /><small><em>('.__('These settings may be overridden for individual articles.').')</em></small>'; ?></legend>
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
<label for="default_pingback_flag">
|
<label for="default_pingback_flag">
|
||||||
|
@ -79,7 +79,7 @@ $plugins = get_plugins();
|
|||||||
|
|
||||||
if (empty($plugins)) {
|
if (empty($plugins)) {
|
||||||
echo '<p>';
|
echo '<p>';
|
||||||
_e("Couldn't open plugins directory or there are no plugins available."); // TODO: make more helpful
|
_e("Couldn&8217;t open plugins directory or there are no plugins available."); // TODO: make more helpful
|
||||||
echo '</p>';
|
echo '</p>';
|
||||||
} else {
|
} else {
|
||||||
?>
|
?>
|
||||||
|
@ -290,7 +290,7 @@ default:
|
|||||||
case 'del_many':
|
case 'del_many':
|
||||||
?>
|
?>
|
||||||
<?php $delete_count = (int) $_GET['delete_count']; ?>
|
<?php $delete_count = (int) $_GET['delete_count']; ?>
|
||||||
<div id="message" class="updated fade"><p><?php printf(__('%1$s %2$s deleted.'), $delete_count, __ngettext('user', 'users', $delete_count) ); ?></p></div>
|
<div id="message" class="updated fade"><p><?php printf(__ngettext('%s user deleted', '%s users deleted', $delete_count), $delete_count); ?></p></div>
|
||||||
<?php
|
<?php
|
||||||
break;
|
break;
|
||||||
case 'add':
|
case 'add':
|
||||||
|
@ -738,22 +738,22 @@ function human_time_diff( $from, $to = '' ) {
|
|||||||
$diff = (int) abs($to - $from);
|
$diff = (int) abs($to - $from);
|
||||||
if ($diff <= 3600) {
|
if ($diff <= 3600) {
|
||||||
$mins = round($diff / 60);
|
$mins = round($diff / 60);
|
||||||
if ($mins <= 1)
|
if ($mins <= 1) {
|
||||||
$since = __('1 min');
|
$mins = 1;
|
||||||
else
|
}
|
||||||
$since = sprintf( __('%s mins'), $mins);
|
$since = sprintf(__ngettext('%s min', '%s mins', $mins), $mins);
|
||||||
} else if (($diff <= 86400) && ($diff > 3600)) {
|
} else if (($diff <= 86400) && ($diff > 3600)) {
|
||||||
$hours = round($diff / 3600);
|
$hours = round($diff / 3600);
|
||||||
if ($hours <= 1)
|
if ($hours <= 1) {
|
||||||
$since = __('1 hour');
|
$hour = 1;
|
||||||
else
|
}
|
||||||
$since = sprintf( __('%s hours'), $hours );
|
$since = sprintf(__ngettext('%s hour', '%s hours', $hours), $hours);
|
||||||
} elseif ($diff >= 86400) {
|
} elseif ($diff >= 86400) {
|
||||||
$days = round($diff / 86400);
|
$days = round($diff / 86400);
|
||||||
if ($days <= 1)
|
if ($days <= 1) {
|
||||||
$since = __('1 day');
|
$days = 1;
|
||||||
else
|
}
|
||||||
$since = sprintf( __('%s days'), $days );
|
$since = sprintf(__('%s day', '%s days', $days), $days);
|
||||||
}
|
}
|
||||||
return $since;
|
return $since;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user