[wp-trac] [WordPress Trac] #25143: Appending registered query vars to home URL sets is_home to true when should be false

WordPress Trac noreply at wordpress.org
Fri Apr 3 14:25:08 UTC 2015


#25143: Appending registered query vars to home URL sets is_home to true when
should be false
-------------------------------------+-----------------------------
 Reporter:  mordauk                  |       Owner:
     Type:  defect (bug)             |      Status:  reopened
 Priority:  normal                   |   Milestone:  Future Release
Component:  Query                    |     Version:  3.6
 Severity:  normal                   |  Resolution:
 Keywords:  has-patch needs-testing  |     Focuses:
-------------------------------------+-----------------------------

Comment (by boonebgorges):

 > The biggest concern I have with this change is the possibility of
 plugins breaking that have registered a query var and are then doing
 something with it on the home page. As of now, they may be accustomed to
 getting the blog page when their query vars are present. With this patch,
 they would get the static front page (if one is configured).

 Yeah, I'm concerned about this too. It seems like far too broad a fix for
 a very particular problem.

 If the specific point is with registering endpoints, why not make it
 possible to call `add_rewrite_endpoint()` in a way that will skip
 registering the query var? It seems to me that the general rule should be:
 if you need a `$_GET` flag, but don't want it to affect the query, then
 don't register the query var; so our strategy should be to find all the
 places where query vars are silently registered (assuming that these
 places are related to features - like rewrite endpoints - that could
 realistically be used by plugin authors in a way that does not affect the
 query), and make sure it's possible to use these features without
 registering query vars.

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


More information about the wp-trac mailing list