Mixin_NextGen_Gallery_Image_Validation

The NextGEN Gallery Mixin NextGen Gallery Image Validation class.

Defined (1)

The class is defined in the following location(s).

/products/photocrati_nextgen/modules/nextgen_data/package.module.nextgen_data.php  
  1. class Mixin_NextGen_Gallery_Image_Validation extends Mixin 
  2. function validation() 
  3. // Additional checks... 
  4. if (isset($this->object->description)) { 
  5. $this->object->description = M_NextGen_Data::strip_html($this->object->description, TRUE); 
  6. if (isset($this->object->alttext)) { 
  7. $this->object->alttext = M_NextGen_Data::strip_html($this->object->alttext, TRUE); 
  8. $this->validates_presence_of('galleryid', 'filename', 'alttext', 'exclude', 'sortorder', 'imagedate'); 
  9. $this->validates_numericality_of('galleryid'); 
  10. $this->validates_numericality_of($this->id()); 
  11. $this->validates_numericality_of('sortorder'); 
  12. return $this->object->is_valid();