]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-admin/options.php
Wordpress 3.2
[autoinstalls/wordpress.git] / wp-admin / options.php
index d802057fe914f1966fd9270c3625e6af54e1bb30..069dcb90f414ac7e956b8e482ecaa477394967be 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /**
- * Options Management Administration Panel.
+ * Options Management Administration Screen.
  *
  * If accessed directly in a browser this page shows a list of all saved options
  * along with editable fields for their values. Serialized data is not supported
@@ -24,10 +24,14 @@ $parent_file = 'options-general.php';
 
 wp_reset_vars(array('action', 'option_page'));
 
+$capability = 'manage_options';
+
 if ( empty($option_page) ) // This is for back compat and will eventually be removed.
        $option_page = 'options';
+else
+       $capability = apply_filters( "option_page_capability_{$option_page}", $capability );
 
-if ( !current_user_can('manage_options') )
+if ( !current_user_can( $capability ) )
        wp_die(__('Cheatin&#8217; uh?'));
 
 // Handle admin email change requests