Community & Support

warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'onthisdate_

Here is the full warning:

warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'onthisdate_admin' was given in C:\wamp\www\drupal\includes\form.inc on line 371.

I have created a menu item like that:
$items['admin/settings/onthisdate'] = array(
'title' => 'On this date module settings',
'description' => 'Description of your On this date settings page',
'page callback' => 'drupal_get_form',
'page arguments' => array('onthisdate_admin'),
'access arguments' => array('access administration pages'),
'type' => MENU_NORMAL_ITEM,
);

When I click on the link "On this date module settings". It show me the given warning.

anybody know the reason of this warning?
Thanks.

Comments

Problem Solve

Thanks.
Problem is Solved.

could you share with us?

Hi Zahid,

Could you please share your solution with the rest of us? How did you solve it? I have a similar problem.