[wp-trac] [WordPress Trac] #34353: Notifications on top of the page for canonical.php and nav-menu-template.php
WordPress Trac
noreply at wordpress.org
Mon Oct 19 08:47:04 UTC 2015
#34353: Notifications on top of the page for canonical.php and nav-menu-
template.php
-------------------------------+-----------------------------
Reporter: theamila | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Canonical | Version: 4.3.1
Severity: normal | Keywords:
Focuses: ui, accessibility |
-------------------------------+-----------------------------
Hello,
We have a problem on our Blog (http://blog.mila.com). Since over half a
year, we get these notifications on top of our wordpress blog:
'''Notice: Undefined index: HTTP_HOST in /opt/wordpress/wp-
includes/canonical.php on line 66'''
'''Notice: Undefined index: HTTP_HOST in /opt/wordpress/wp-includes/nav-
menu-template.php on line 558'''
The notifications come and go, so i don't know what the problem is..
This is line 66 in the canonical file:
{{{#!php
<?php
$requested_url .= $_SERVER['HTTP_HOST'];
}}}
And this is line 558 in nav-menu-template.php:
{{{#!php
<?php
$current_url = set_url_scheme( 'http://' . $_SERVER['HTTP_HOST'] .
$_root_relative_current );
}}}
We know that the notification is shown because the variable HTTP_HOST is
not set, but we don't know how to fix that. It would be great if you could
help
--
Ticket URL: <https://core.trac.wordpress.org/ticket/34353>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list