You are here

function easychart_field_csv_validate in Easychart 7.3

CSV element validation function.

Parameters

$element: The CSV element

1 string reference to 'easychart_field_csv_validate'
easychart_field_widget_form in ./easychart.module
Implements hook_field_widget_form().

File

./easychart.module, line 236
Easychart module file.

Code

function easychart_field_csv_validate($element) {
  if ($element['#csv_required'] && empty($element['#value'])) {
    form_set_error('csv', t('Please create an Easychart chart before saving.'));
  }
}