Skip to content

hook_civicrm_validate

Removed Hook

This hook was removed in v4.7 in favor of hook_civicrm_validateForm.

Summary

This hook was invoked during all CiviCRM form validation. An array of errors detected was returned, otherwise validation succeeded.

Availability

This hook was removed in v4.7.

Definition

hook_civicrm_validate($formName, &$fields, &$files, &$form)

Parameters

  • string $formName - The name of the form.
  • array &$fields - the POST parameters as filtered by QF
  • array &$files - the FILES parameters as sent in by POST
  • array &$form - the form object

Returns

  • mixed - formRule hooks return a boolean or an array of error messages which display a QF Error