I'm running Drupal 6.2 with Webform 6.x-2.1.1 and I'm getting the following error messages when submitting a form that I just designed:

# warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_textfield' was given in /home/variantc/public_html/essl/includes/theme.inc on line 591.
# warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_select' was given in /home/variantc/public_html/essl/includes/theme.inc on line 591.
# warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_select' was given in /home/variantc/public_html/essl/includes/theme.inc on line 591.
# warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_select' was given in /home/variantc/public_html/essl/includes/theme.inc on line 591.
# warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_pagebreak' was given in /home/variantc/public_html/essl/includes/theme.inc on line 591.

The form data submits both to the database and I can view the results in the Webform interface. I also get the e-mail submission copy. So why is this error happening. Please help!

Thanks!

CommentFileSizeAuthor
#10 webform_theme_missing.patch1.03 KBquicksketch
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

ImmanuelPhillips’s picture

I get same errors! Help!

INTERACSS-1’s picture

I also get the same, please help!!

Apart from that great module!

J

quicksketch’s picture

This is a bit strange, these functions should be loaded when Webform creates the form. Is there anything special about the configuration of your form? (Any additional validation or submit code, is the form displayed in a custom way, etc).

ImmanuelPhillips’s picture

I used webform to create a support desk system. There is no extra coding in there, just using the functions webform gives me.

njcheng’s picture

I'm also getting the same errors, but only get errors when making a multi-page form with "pagebreak". I can't seem to find a correlation between the theme_webform_mail_[component] and the actual components I have in the form though...

njcheng’s picture

Has anyone found a resolution to this outside of disabling page break? Thanks!

-NC

bhagg’s picture

I am receiving similar warnings when I try to edit a node. Viewings the node is fine but now I don't have the ability to even delete it. Running version 5.3. Any ideas on how to remove this?

warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'chaptr_info_node_form' was given in /home/sawj/public_html/includes/form.inc on line 217.

shali.nguyen’s picture

this is what i'm getting:

warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_date' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_date' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_select' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_textfield' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_select' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_textfield' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_textfield' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_textfield' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_textfield' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_textfield' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_textfield' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_textfield' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_textfield' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_textfield' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_textfield' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_textfield' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'theme_webform_mail_pagebreak' was given in C:\Apache22\htdocs\ucsf\includes\theme.inc on line 597. 
warning: mail() [function.mail]: SMTP server response: 501 5.5.4 Invalid Address in C:\Apache22\htdocs\ucsf\includes\mail.inc on line 193. 
Unable to send e-mail. Please contact the site admin, if the problem persists. 
sampeckham’s picture

Same here with Drupal 6.3. Everything worked fine when I had the form on one page, but got the error as soon as I added a 'Pagebreak'

I do have some additional processing, but this still worked when the error showed, and didn't cause a problem before I used Pagebreak anyway.

Solutions?

quicksketch’s picture

Title: Warning: call_user_func_array Error on form submission in Drupal 6.2 » Warning: call_user_func_array Error on form submission
Version: 6.x-2.1.1 » 6.x-2.1.2
Component: Miscellaneous » Code
Assigned: ambientdrup » Unassigned
Category: support » bug
Priority: Critical » Normal
Status: Active » Needs review
FileSize
1.03 KB

I've never actually seen the errors, but I think I've discovered where this problem is occuring. My e-mails have come through but they don't have the proper default theming. Some of the components are also out of order: elements on the last page start the e-mail, followed by the ones from other pages. This patch should correct both problems.

Since I can't seem to reproduce the exact error, I'd appreciate confirmation that this patch will solve the problem.

dmweyer’s picture

I don't have command line access to the server my site is hosted on. Is there a manually way to apply this patch? i.e. to manually edit the relevant pages?

quicksketch’s picture

Status: Needs review » Fixed

I went ahead and committed this fix because I feel like it's likely to fix the problem. Please reopen if this patch does not indeed solve the problem.

dmweyer: you can manually apply the patch by adding the lines to the webform.module that start with a "+" and remove lines that begin with a "-". Since this patch only adds lines, you just have to add in the two lines from the patch. Of course, you can also run patch locally then upload the new file to the server.

dmweyer’s picture

Doh, dont know why I didnt think of that, thanks quicksketch

sampeckham’s picture

Thanks for that tip on patching. I've not done any patches before, so being a small change it was easy just to add the lines of code to the file.

It all seems to work too, not getting those errors on multi-page forms. Thanks!

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.

ionmedia’s picture

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