[wp-trac] [WordPress Trac] #30598: Multisite Subdomain doesn't properly redirect users logging in to the primary site
WordPress Trac
noreply at wordpress.org
Thu Dec 10 16:45:05 UTC 2015
#30598: Multisite Subdomain doesn't properly redirect users logging in to the
primary site
--------------------------------+------------------------
Reporter: Ipstenu | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: 4.5
Component: Networks and Sites | Version:
Severity: normal | Resolution:
Keywords: needs-patch | Focuses: multisite
--------------------------------+------------------------
Comment (by ShinichiN):
I'm wondering if it is better to use the `allowed_redirect_hosts` filter
in `wp_validate_redirect()` and add the subdomain host name to the
`$allowed_hosts` array.
{{{#!php
<?php
/**
* Filter the whitelist of hosts to redirect to.
*
* @since 2.3.0
*
* @param array $hosts An array of allowed hosts.
* @param bool|string $host The parsed host; empty if not isset.
*/
$allowed_hosts = (array) apply_filters( 'allowed_redirect_hosts',
array($wpp['host']), isset($lp['host']) ? $lp['host'] : '' );
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/30598#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list