[wp-trac] [WordPress Trac] #22325: Abstract GPCS away from the superglobals

WordPress Trac noreply at wordpress.org
Sat Nov 3 00:30:13 UTC 2012


#22325: Abstract GPCS away from the superglobals
-------------------------+-----------------------------
 Reporter:  rmccue       |       Owner:
     Type:  enhancement  |      Status:  new
 Priority:  normal       |   Milestone:  Future Release
Component:  General      |     Version:
 Severity:  minor        |  Resolution:
 Keywords:               |
-------------------------+-----------------------------

Comment (by MikeSchinkel):

 Replying to [comment:21 CaptainN]:
 > Related, there is a hole in the model we've been discussing, which is
 sometimes it's convenient to change the POST or GET data. Neither attempt
 has a solution for allowing that. Adding it would seem to complicate
 things.

 Could easily be like the following with no real added complexity:

 {{{
 set_GET( 'test', 'abc123' );
 set_POST( array( 'foo', 'bar'), array( 'baz' => 'bazoom') );
 }}}

 Beyond that I'll wait to hear for the ''"powers that be"'' weigh in. :)

 P.S. Also updated the code to add `set_GET()`, `set_POST()` and
 `set_REQUEST()` as well as created a `WP_GPCS` class that wraps copies of
 `$_GET`, `$_POST` and `$_REQUEST`.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/22325#comment:22>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list