Drupal 7 在ctools弹出drupal 7中获取对未定义函数webform\u component\u edit\u form\u validate的错误调用

Drupal 7 在ctools弹出drupal 7中获取对未定义函数webform\u component\u edit\u form\u validate的错误调用,drupal-7,drupal-webform,drupal-ctools,Drupal 7,Drupal Webform,Drupal Ctools,我正在使用webform模块创建表单。我不需要自定义webform\u组件\u编辑\u表单。所以 我已经修改了网络表单、组件和编辑表单在这个表单中,我添加了带有#ajax属性的select元素。当我在url中打开它时,它工作正常。但当我在ctools中打开此表单时,我得到了一个错误 Call to undefined function webform_component_edit_form_validate() in ../includes/form.inc webform\u compone

我正在使用webform模块创建表单。我不需要自定义webform\u组件\u编辑\u表单。所以 我已经修改了网络表单、组件和编辑表单在这个表单中,我添加了带有#ajax属性的select元素。当我在url中打开它时,它工作正常。但当我在ctools中打开此表单时,我得到了一个错误

Call to undefined function webform_component_edit_form_validate() in ../includes/form.inc
webform\u component\u edit\u form\u validate我是用webform/includedes/webform.components.inc编写的


任何人都可以告诉我哪里出了错。

它存在于webform/includes/webform.components.inc中,所以它可能没有被包含,因为您正在将它与表单alter集成

尝试将其添加到您正在修改的表单项上方的表单更改中

require_once drupal_get_path('module', 'webform') . '/includes/webform.components.inc';
我用

在我的模块的上面。 现在它可以正常工作了

module_load_include('inc', 'webform', '/includes/webform.components');