Cakephp How to validate my D.O.B field so that the age will not be greater than the period of residence entered
问题 i have two fields in my form that should correspond to each other.If a users enters the date of birth,in the D.O.B field,he/she must not be allowed to enter a period of residence greater than the D.O.B my two fields in the add.ctp are as follows echo $this->Form->input('DOB',array('label' => 'Date of birth*', 'minYear' => 1900, 'maxYear' => 2000)); echo $this->Form->input('period_of_residence', array('label' =>'Period of residence in Zimbabwe')); So now i don't know how i validate the two so