Trim trailing whitespace.

git-svn-id: https://develop.svn.wordpress.org/trunk@15235 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren
2010-06-11 20:19:35 +00:00
parent 895e6c5dfe
commit 82be9621ec
8 changed files with 35 additions and 35 deletions
+9 -9
View File
@@ -844,7 +844,7 @@ function add_menu_page( $page_title, $menu_title, $capability, $menu_slug, $func
// No parent as top level
$_parent_pages[$menu_slug] = false;
return $hookname;
}
@@ -955,7 +955,7 @@ function add_submenu_page( $parent_slug, $page_title, $menu_title, $capability,
// No parent as top level
$_parent_pages[$menu_slug] = $parent_slug;
return $hookname;
}
@@ -1173,18 +1173,18 @@ function add_comments_page( $page_title, $menu_title, $capability, $menu_slug, $
/**
* Get the url to access a particular menu page based on the slug it was registered with.
*
*
* If the slug hasn't been registered properly no url will be returned
*
*
* @since 3.0
*
*
* @param string $menu_slug The slug name to refer to this menu by (should be unique for this menu)
* @param bool $echo Whether or not to echo the url - default is true
* @return string the url
*/
function menu_page_url($menu_slug, $echo = true) {
global $_parent_pages;
if ( isset( $_parent_pages[$menu_slug] ) ) {
if ( $_parent_pages[$menu_slug] ) {
$url = admin_url($_parent_pages[$menu_slug] . '?page=' . $menu_slug);
@@ -1194,12 +1194,12 @@ function menu_page_url($menu_slug, $echo = true) {
} else {
$url = '';
}
$url = esc_url($url);
if ( $echo )
echo $url;
return $url;
}