Make WordPress Core

Opened 8 years ago

Last modified 8 years ago

#15083 closed defect (bug)

Apache rewrite loop on subdirectory install — at Version 2

Reported by: wpmuguru Owned by:
Milestone: 3.1 Priority: normal
Severity: normal Version:
Component: Multisite Keywords: has-patch commit
Focuses: Cc:

Description (last modified by wpmuguru)

If a requested file under the wp-content directory does not exist, this creates a rewrite loop for the file. Let's say /subsite/wp-content/themes/theme-x/images/abc.gif does not exist, then the rewrite that is invoked is:

RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]

The first rewrite pass rewrites the url to /wp-content/themes/theme-x/images/abc.gif which also does not exist. However, the rewritten request still matches the rewrite rule because the question mark ^([_0-9a-zA-Z-]+/)? makes it so the rewrite rule also applies to /wp-content/themes/theme-x/images/abc.gif.

Change History (3)

8 years ago

#1 @wpmuguru
8 years ago

I don't have IIS to work with so I did not patch those rules. If someone with IIS could makes similar changes to the IIS rules, that would be great.

#2 @wpmuguru
8 years ago

  • Description modified (diff)
Note: See TracTickets for help on using tickets.