[wp-trac] [WordPress Trac] #17376: Multisite Subfolders and bunk /wp-admin areas
WordPress Trac
noreply at wordpress.org
Wed Mar 19 04:37:31 UTC 2014
#17376: Multisite Subfolders and bunk /wp-admin areas
-------------------------------------------------+-------------------------
Reporter: MadtownLems | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: 3.9
Component: Bootstrap/Load | Version:
Severity: normal | Resolution:
Keywords: has-patch dev-feedback needs-unit- | Focuses: multisite
tests |
-------------------------------------------------+-------------------------
Comment (by jeremyfelt):
[https://core.trac.wordpress.org/attachment/ticket/17376/17376.3.diff
17376.3.diff] takes a different approach from other patches on this ticket
and watches for admin requests during `get_site_by_path()`. If
`is_admin()` returns true, it alters the search from multiple possible
path segments to one possible path segment.
For `foo.bar/site2` on a network where only `foo.bar/` and
`foo.bar/site1/` exist:
* `foo.bar/site2/` will search both `site2/` and `/` as paths
* `foo.bar/site2/wp-admin/` will search only `site2/` as a path.
When a site is not found, the patch redirects to the network's primary
site `wp-admin/` path. At that point, if the user does not have access, we
already throw a fairly helpful message showing the current sites that the
user does have access to.
If the user does have access, the redirect is silent. I'm not sure that we
should worry about additional admin notices for this scenario.
Anything outside the range of possible path segments—`foo.bar/site2/page1
/wp-admin/` will result in a 404 for the primary site, the current
behavior.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/17376#comment:18>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list