[wp-trac] [WordPress Trac] #20699: AJAX Actions now pass the action name as an arg

WordPress Trac wp-trac at lists.automattic.com
Thu May 24 06:13:34 UTC 2012


#20699: AJAX Actions now pass the action name as an arg
--------------------------------------+-----------------------
 Reporter:  sivel                     |       Owner:  ryan
     Type:  defect (bug)              |      Status:  reopened
 Priority:  high                      |   Milestone:  3.4
Component:  Administration            |     Version:  3.4
 Severity:  critical                  |  Resolution:
 Keywords:  2nd-opinion dev-feedback  |
--------------------------------------+-----------------------

Comment (by nacin):

 Me in IRC with MarkJaquith: What had happened in 3.3 is we had done
 $action = $_GET['action'] (or $_POST) in global scope, then just used
 $action down the line. Once we encapsulated things into functions, since
 we decided to pass in $action, it was just convenient. I think sivel was
 relying on some pretty damn edge behavior that I'd be okay with breaking
 compatibility on that. But since we didn't advertise it (I didn't realize
 it, none of us did), I'd be okay with holding off on it until 3.5.

 So let's do $action = $_REQUEST['action']; in each of these functions, and
 try this again in early 3.5, and warn people about it. Unfortunately we
 didn't recognize it as a backwards incompatible behavioral change at the
 time.

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


More information about the wp-trac mailing list