Saving the settings for my image field results in this error:

Fatal error: Call to undefined function _field_permissions_field_settings_form_submit() in [path]/includes/form.inc on line 1389

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

tsvenson’s picture

Got a similar today, with only the row number different:

Fatal error: Call to undefined function _field_permissions_field_settings_form_submit() in [path]\includes\form.inc on line 1414

This is with Drupal 7.7 and when I tried to enable a File Field Sources option for a content type, but no field permission options are set for this image field.

I get the WSOD, but when I reload the image field edit tab, the setting is applied.

mh86’s picture

I'm getting the same error after saving a field

chalee’s picture

I'm also getting this error when I try to save settings for a date field with repeat options

chalee’s picture

Specifically on my machine the error comes when the module http://drupal.org/project/date_repeat_presets is enabled.

GiorgosK’s picture

getting this error on saving image field attached to a vocabulary (on nodes it does not happen)

I am not even using the functionality of field_permissions I have just installed it just to see how it works but not using it ...

zhgenti’s picture

Status: Active » Needs review
FileSize
8.53 KB

Hi,

It happens when form has upload file control uses ajax. When ajax is used, form is cached and alter functions aren't called. Module owner performs file inclusion in the alter. Drupal hooks better to be placed in the .module file, or .inc files should be included by Drupal automatically. For example in the hook_menu or hook_theme.
Here is patch which fixes this issue. It moves few functions from .inc file into .module file.

Thanks,
Dmitry

13rac1’s picture

Status: Needs review » Reviewed & tested by the community

Fixes the problem. Applies correctly.

David_Rothstein’s picture

Status: Reviewed & tested by the community » Needs review
FileSize
777 bytes

Can't we just do the attached instead?

It fixes the bug for me, and this kind of situation is exactly what form_load_include() was designed for.

RobLoach’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

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

Anonymous’s picture

Issue summary: View changes

Changing path in error message to be more generic.