You are here

function imageapi_imagemagick_quality_element_validate in ImageAPI 6

Same name and namespace in other branches
  1. 5 imageapi_imagemagick.module \imageapi_imagemagick_quality_element_validate()
1 string reference to 'imageapi_imagemagick_quality_element_validate'
imageapi_imagemagick_settings_form in ./imageapi_imagemagick.module
Settings form for the toolkit.

File

./imageapi_imagemagick.module, line 93
ImageMagick toolkit functions

Code

function imageapi_imagemagick_quality_element_validate($element) {
  if ($element['#value'] < 0 || $element['#value'] > 100) {
    form_set_error($element['#name'], t('Compression Quality must be a value between 0 and 100.'));
  }
}