[wp-trac] [WordPress Trac] #40979: add_rewrite_endpoint() doesn't work when applied to unattached media

WordPress Trac noreply at wordpress.org
Mon Jun 12 04:45:46 UTC 2017


#40979: add_rewrite_endpoint() doesn't work when applied to unattached media
---------------------------+------------------------------
 Reporter:  henry.wright   |       Owner:
     Type:  defect (bug)   |      Status:  new
 Priority:  normal         |   Milestone:  Awaiting Review
Component:  Rewrite Rules  |     Version:
 Severity:  normal         |  Resolution:
 Keywords:  close          |     Focuses:
---------------------------+------------------------------
Changes (by dd32):

 * keywords:   => close


Comment:

 This makes sense to me as-is, although isn't what would be expected by
 some.

 `EP_ATTACHMENT` applies to attachment rules only, these rules are for
 attached media only, ie. `/2017/post-name/attachment-name/`.
 It does not apply to the page rules, which is how the unattached media is
 queried.

 For reference, here's the rewrite rule hit:
 {{{
 url: /unattached-media/
 regex: (.?.+?)(?:/([0-9]+))?/?$
 query: pagename=unattached-media&page=
 }}}

 This is quite possibly a wontfix.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/40979#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list