diff --git a/core/includes/common.inc b/core/includes/common.inc index c9913a2..61ed705 100644 --- a/core/includes/common.inc +++ b/core/includes/common.inc @@ -2182,7 +2182,7 @@ function url($path = NULL, array $options = array()) { } // The special path '' links to the default front page. - if ($path == '') { + if ($path == '' || $path == '') { $path = ''; } elseif (!empty($path) && !$options['alias']) { diff --git a/core/includes/menu.inc b/core/includes/menu.inc index 8574dbe..0a4ec5c 100644 --- a/core/includes/menu.inc +++ b/core/includes/menu.inc @@ -1603,7 +1603,13 @@ function theme_menu_link(array $variables) { if ($element['#below']) { $sub_menu = drupal_render($element['#below']); } - $output = l($element['#title'], $element['#href'], $element['#localized_options']); + + if ($element['#href'] != '') { + $output = l($element['#title'], $element['#href'], $element['#localized_options']); + } + else { + $output = $element['#title']; + } return '' . $output . $sub_menu . "\n"; } @@ -3012,7 +3018,7 @@ function menu_link_save(&$item, $existing_item = array(), $parent_candidates = a // This is the easiest way to handle the unique internal path '', // since a path marked as external does not need to match a router path. - $item['external'] = (url_is_external($item['link_path']) || $item['link_path'] == '') ? 1 : 0; + $item['external'] = (url_is_external($item['link_path']) || $item['link_path'] == '' || $item['link_path'] == '') ? 1 : 0; // Load defaults. $item += array( 'menu_name' => 'navigation', diff --git a/core/includes/path.inc b/core/includes/path.inc index 07aeee5..db63e5e 100644 --- a/core/includes/path.inc +++ b/core/includes/path.inc @@ -577,7 +577,7 @@ function drupal_valid_path($path, $dynamic_allowed = FALSE) { global $menu_admin; // We indicate that a menu administrator is running the menu access check. $menu_admin = TRUE; - if ($path == '' || url_is_external($path)) { + if ($path == '' || $path == '' || url_is_external($path)) { $item = array('access' => TRUE); } elseif ($dynamic_allowed && preg_match('/\/\%/', $path)) { diff --git a/core/includes/theme.inc b/core/includes/theme.inc index 2d1d375..c24b47f 100644 --- a/core/includes/theme.inc +++ b/core/includes/theme.inc @@ -1665,7 +1665,12 @@ function theme_links($variables) { $class[] = 'active'; } // Pass in $link as $options, they share the same keys. - $item = l($link['title'], $link['href'], $link); + if ($link['href'] != '') { + $item = l($link['title'], $link['href'], $link); + } + else { + $item = $link['title']; + } } // Handle title-only text items. else {