From 5a205f578b157111454d62cb249116451c7f0c38 Mon Sep 17 00:00:00 2001 From: Matt Mullenweg Date: Tue, 4 Jul 2006 17:19:15 +0000 Subject: [PATCH] More intuitive navigation, fixes #2471 git-svn-id: https://develop.svn.wordpress.org/trunk@3947 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/menu.php | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/wp-admin/menu.php b/wp-admin/menu.php index cbeb16ba47..514d485bd6 100644 --- a/wp-admin/menu.php +++ b/wp-admin/menu.php @@ -5,8 +5,16 @@ // The minimum level the user needs to access the item: between 0 and 10 // The URL of the item's file $menu[0] = array(__('Dashboard'), 'read', 'index.php'); -$menu[5] = array(__('Write'), 'edit_posts', 'post-new.php'); -$menu[10] = array(__('Manage'), 'edit_posts', 'edit.php'); + +if ( strstr($_SERVER['REQUEST_URI'], 'edit-pages.php') ) + $menu[5] = array(__('Write'), 'edit_pages', 'page-new.php'); +else + $menu[5] = array(__('Write'), 'edit_posts', 'post-new.php'); +if ( strstr($_SERVER['REQUEST_URI'], 'page-new.php') ) + $menu[10] = array(__('Manage'), 'edit_pages', 'edit-pages.php'); +else + $menu[10] = array(__('Manage'), 'edit_posts', 'edit.php'); + $menu[20] = array(__('Bookmarks'), 'manage_links', 'link-manager.php'); $menu[25] = array(__('Presentation'), 'switch_themes', 'themes.php'); $menu[30] = array(__('Plugins'), 'activate_plugins', 'plugins.php');