diff --git a/wp-admin/edit.php b/wp-admin/edit.php
index 5ebe980af2..bf2f9304fe 100644
--- a/wp-admin/edit.php
+++ b/wp-admin/edit.php
@@ -90,8 +90,6 @@ if ( empty($_GET['mode']) )
else
$mode = attribute_escape($_GET['mode']); ?>
-
-
diff --git a/wp-admin/includes/template.php b/wp-admin/includes/template.php
index f6aaa0a354..f804fdb329 100644
--- a/wp-admin/includes/template.php
+++ b/wp-admin/includes/template.php
@@ -2650,7 +2650,7 @@ function do_meta_boxes($page, $context, $object) {
global $wp_meta_boxes;
static $already_sorted = false;
- do_action('do_meta_boxes', $page, $context, $object);
+ //do_action('do_meta_boxes', $page, $context, $object);
$hidden = (array) get_user_option( "meta-box-hidden_$page" );
@@ -3177,10 +3177,19 @@ function _post_states($post) {
function screen_meta($screen) {
global $wp_meta_boxes;
- $column_screens = array('edit-posts' => 'post', 'edit-pages' => 'page', 'edit-tags' => 'tag', 'edit-categories' => 'category',
- 'edit-link-categories' => 'link-category', 'edit-links' => 'link', 'edit-users' => 'user', 'edit-media' => 'media',
+ $screen = str_replace('.php', '', $screen);
+
+ $column_screens = array('edit' => 'post', 'edit-pages' => 'page', 'edit-tags' => 'tag', 'categories' => 'category',
+ 'edit-link-categories' => 'link-category', 'link-manager' => 'link', 'users' => 'user', 'upload' => 'media',
'edit-comments' => 'comment');
+ $screen = str_replace('-new', '', $screen);
+ $screen = str_replace('-add', '', $screen);
+ $meta_screens = array('index' => 'dashboard');
+
+ if ( isset($meta_screens[$screen]) )
+ $screen = $meta_screens[$screen];
+error_log("screen: $screen");
$show_screen = false;
if ( !empty($wp_meta_boxes[$screen]) || !empty($column_screens[$screen]) )
$show_screen = true;
diff --git a/wp-admin/index.php b/wp-admin/index.php
index 386878a0ff..b4921ce533 100644
--- a/wp-admin/index.php
+++ b/wp-admin/index.php
@@ -28,8 +28,6 @@ require_once('admin-header.php');
$today = current_time('mysql', 1);
?>
-
-
diff --git a/wp-admin/link-add.php b/wp-admin/link-add.php
index de0f268bf4..e7d861bff9 100644
--- a/wp-admin/link-add.php
+++ b/wp-admin/link-add.php
@@ -20,17 +20,6 @@ wp_reset_vars(array('action', 'cat_id', 'linkurl', 'name', 'image',
wp_enqueue_script('link');
wp_enqueue_script('xfn');
-$link_added = ( isset($_GET['added']) && '' != $_POST['link_name'] ) ?
- '
' . __('Link added.') . '
' : '';
-
-require('admin-header.php');
-?>
-
-
-
-
-
-
-
-
diff --git a/wp-admin/link.php b/wp-admin/link.php
index b123bc6d5f..f4b9740b6b 100644
--- a/wp-admin/link.php
+++ b/wp-admin/link.php
@@ -106,7 +106,6 @@ switch ($action) {
if (!$link = get_link_to_edit($link_id))
wp_die(__('Link not found.'));
- include_once ('admin-header.php');
include ('edit-link-form.php');
include ('admin-footer.php');
break;
diff --git a/wp-admin/page-new.php b/wp-admin/page-new.php
index ab2215ddba..05ad921073 100644
--- a/wp-admin/page-new.php
+++ b/wp-admin/page-new.php
@@ -19,20 +19,13 @@ add_thickbox();
wp_enqueue_script('media-upload');
wp_enqueue_script('word-count');
-require_once('admin-header.php');
-?>
-
-
-
-
-
-
-
+include('admin-footer.php');
+
+?>
diff --git a/wp-admin/page.php b/wp-admin/page.php
index 1b5ddbe99b..baf064d231 100644
--- a/wp-admin/page.php
+++ b/wp-admin/page.php
@@ -115,8 +115,6 @@ case 'edit':
}
}
- require_once('admin-header.php');
-
if ( !current_user_can('edit_page', $page_ID) )
die ( __('You are not allowed to edit this page.') );
diff --git a/wp-admin/post-new.php b/wp-admin/post-new.php
index 233e6f4c89..229f3d06c3 100644
--- a/wp-admin/post-new.php
+++ b/wp-admin/post-new.php
@@ -19,9 +19,8 @@ add_thickbox();
wp_enqueue_script('media-upload');
wp_enqueue_script('word-count');
-require_once ('./admin-header.php');
-
-if ( ! current_user_can('edit_posts') ) { ?>
+if ( ! current_user_can('edit_posts') ) {
+ require_once ('./admin-header.php'); ?>
edit_posts capability to your user, in order to be authorized to post.
You can also e-mail the admin to ask for a promotion.
@@ -33,15 +32,6 @@ When you’re promoted, just reload this page and you’ll be able to bl
exit();
}
-if ( isset($_GET['posted']) && $_GET['posted'] ) : $_GET['posted'] = (int) $_GET['posted']; ?>
-
-
-
-
-
-
-
diff --git a/wp-admin/users.php b/wp-admin/users.php
index 7b9514eeaa..0e40ed562f 100644
--- a/wp-admin/users.php
+++ b/wp-admin/users.php
@@ -220,8 +220,6 @@ default:
}
endif; ?>
-
-