[wp-trac] [WordPress Trac] #13977: home link current_page nav menu defect on IIS
WordPress Trac
wp-trac at lists.automattic.com
Fri Jun 18 14:08:56 UTC 2010
#13977: home link current_page nav menu defect on IIS
--------------------------+-------------------------------------------------
Reporter: andddd | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: 3.0.1
Component: Menus | Version: 3.0
Severity: normal | Keywords: menu highlight current_page_item
--------------------------+-------------------------------------------------
I'm using IIS and fresh WordPress 3.0 without any URL Rewrite software and
I found a defect in wp-includes/nav-menu-template.php (line 365) which
prevents home link highlight.
{{{
$current_url = ( is_ssl() ? 'https://' : 'http://' ) .
$_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];
...
if ( untrailingslashit($current_url) == home_url() ) {
$classes[] = 'menu-item-home';
...
}}}
$current_url is always {{{http(s)://mysite.com/index.php}}} on the front
page and my home_url() is always {{{http(s)://mysite.com}}} so both
variables never be equal.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/13977>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list