AJAX callback cannot take object method due to function_exists() check

Created on 25 January 2016, almost 9 years ago
Updated 8 November 2023, about 1 year ago

Similar issue has been fixed in Drupal 8 core, however the bug still exists in 7.

Callback works successfully when function_exists() is swapped out for is_callable().

Example:

$form['checkbox'] = array(
  '#type' => 'checkboxes',
  '#options' => $options,
  '#ajax' => array(
    'callback' => array($this, 'ajaxCallbackFunction'),
  ),
);
πŸ› Bug report
Status

Closed: duplicate

Version

7.0 ⚰️

Component
AjaxΒ  β†’

Last updated 1 day ago

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

No activities found.

Production build 0.71.5 2024