103 if(! count($this->rules) )
return;
107 foreach($this->rules as $rule) {
108 list($fieldname, $error_message, $function_name) = $rule;
110 if (!$this->$function_name($object->Get($fieldname))) {
112 $c->messages[] = $error_message;
197 if(!$field_string)
return true;
199 switch($session->date_format_type) {
201 if (!preg_match(
'/^([0-9]{4})[\/\-]([0-9]{1,2})[\/\-]([0-9]{1,2})$/', $field_string, $regs))
return false;
202 $day = intval($regs[3]);
203 $month = intval($regs[2]);
204 $year = intval($regs[1]);
208 if (!preg_match(
'/^([0-9]{1,2})[\/\-]([0-9]{1,2})[\/\-]([0-9]{4})$/', $field_string, $regs))
return false;
209 $day = intval($regs[2]);
210 $month = intval($regs[1]);
211 $year = intval($regs[3]);
216 if (!preg_match(
'/^([0-9]{1,2})[\/\-]([0-9]{1,2})[\/\-]([0-9]{4})$/', $field_string, $regs))
return false;
217 $day = intval($regs[1]);
218 $month = intval($regs[2]);
219 $year = intval($regs[3]);
221 return (checkdate ($month, $day, $year));