*/ class LSformRule_required extends LSformRule { /** * Validate form element value * * @param mixed $value The value to validate * @param array $options Validation options * @param LSformElement &$formElement The related LSformElement object * * @return boolean True if value is valid, False otherwise */ public static function validate($value, $options, &$formElement) { return ((string)$value != ''); } }