Posted by mkadin on March 11, 2013 at 5:40pm
Project:
Drupal core
Introduced in branch:
8.x Description:
A new AjaxController has been added to core to handle Ajax requests from Drupal's Ajax-enabled form elements and links. Ajax requests from elements using the '#ajax' property will be sent with the MIME type 'application/vnd.drupal-ajax.' Requests with that MIME type will be routed through a new AjaxController class, which will make sure that any returned content is packaged in an AjaxResponse.
Module developers can use the Ajax API just as they did in Drupal 7 in that a function handling an Ajax request can return HTML or a render array; AjaxController will wrap it properly for insertion on the page.
Impacts:
Module developers