[wp-trac] [WordPress Trac] #20082: Admin bar links to wrong site in multisite (subdomain) network
WordPress Trac
wp-trac at lists.automattic.com
Tue Feb 21 08:41:46 UTC 2012
#20082: Admin bar links to wrong site in multisite (subdomain) network
-------------------------------+------------------------------
Reporter: niklasbr | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Administration | Version: 3.3.1
Severity: major | Resolution:
Keywords: reporter-feedback |
-------------------------------+------------------------------
Description changed by dd32:
Old description:
> The code
> ` foreach ( $actions as $link => $action ) {
> list( $title, $id ) = $action;
>
> $wp_admin_bar->add_menu( array(
> 'parent' => 'new-content',
> 'id' => $id,
> 'title' => $title,
> 'href' => admin_url( $link )
> ) );
> }
> `
> generates the wrong URL, whenever I visit a site that has the URL
> subsite.subsite.example.com but generates the correct URL if the URL is
> of the pattern subsite.example.com. On subsite.subsite.example.com the
> admin bar will generate links to subsite.example.com.
New description:
The code
{{{
foreach ( $actions as $link => $action ) {
list( $title, $id ) = $action;
$wp_admin_bar->add_menu( array(
'parent' => 'new-content',
'id' => $id,
'title' => $title,
'href' => admin_url( $link )
) );
}
}}}
generates the wrong URL, whenever I visit a site that has the URL
subsite.subsite.example.com but generates the correct URL if the URL is of
the pattern subsite.example.com. On subsite.subsite.example.com the admin
bar will generate links to subsite.example.com.
--
--
Ticket URL: <http://core.trac.wordpress.org/ticket/20082#comment:2>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list