More cap checks, for trunk

git-svn-id: http://svn.automattic.com/wordpress/trunk@11764 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
azaozz 2009-08-02 02:23:54 +00:00
parent 9bb224cf1e
commit 3d7a5dce98
6 changed files with 19 additions and 0 deletions

View File

@ -6,6 +6,9 @@
* @subpackage Administration * @subpackage Administration
*/ */
if ( !current_user_can('manage_categories') )
wp_die(__('You do not have sufficient permissions to edit categories for this blog.'));
/** /**
* @var object * @var object
*/ */

View File

@ -6,6 +6,9 @@
* @subpackage Administration * @subpackage Administration
*/ */
if ( !current_user_can('manage_categories') )
wp_die(__('You do not have sufficient permissions to edit link categories for this blog.'));
/** /**
* @var object * @var object
*/ */

View File

@ -6,6 +6,9 @@
* @subpackage Administration * @subpackage Administration
*/ */
if ( !current_user_can('manage_categories') )
wp_die(__('You do not have sufficient permissions to edit tags for this blog.'));
if ( empty($tag_ID) ) { ?> if ( empty($tag_ID) ) { ?>
<div id="message" class="updated fade"><p><strong><?php _e('A tag was not selected for editing.'); ?></strong></p></div> <div id="message" class="updated fade"><p><strong><?php _e('A tag was not selected for editing.'); ?></strong></p></div>
<?php <?php

View File

@ -9,6 +9,9 @@
/** Load WordPress Bootstrap */ /** Load WordPress Bootstrap */
require_once ('admin.php'); require_once ('admin.php');
if ( !current_user_can('edit_files') )
wp_die(__('You do not have sufficient permissions to export the content of this blog.'));
/** Load WordPress export API */ /** Load WordPress export API */
require_once('includes/export.php'); require_once('includes/export.php');
$title = __('Export'); $title = __('Export');

View File

@ -8,6 +8,10 @@
/** Load WordPress Bootstrap */ /** Load WordPress Bootstrap */
require_once ('admin.php'); require_once ('admin.php');
if ( !current_user_can('edit_files') )
wp_die(__('You do not have sufficient permissions to import content in this blog.'));
$title = __('Import'); $title = __('Import');
require_once ('admin-header.php'); require_once ('admin-header.php');
$parent_file = 'tools.php'; $parent_file = 'tools.php';

View File

@ -9,6 +9,9 @@
/** Load WordPress Administration Bootstrap */ /** Load WordPress Administration Bootstrap */
require_once('admin.php'); require_once('admin.php');
if ( ! current_user_can('manage_links') )
wp_die(__('You do not have sufficient permissions to add links to this blog.'));
$title = __('Add New Link'); $title = __('Add New Link');
$parent_file = 'link-manager.php'; $parent_file = 'link-manager.php';