Closed Sikito closed 6 years ago
wait for 4.2.3
--- html
<input type="text" data-validate="custom=myValidateFuncName">
--- javascript
function myValidateFuncName(val){
val = parseInt(val);
return Metro.utils.isInt(val) && (val > 3 && val < 9);
}
I will wait, thanks
I'm making a form where i want to check if the date choosen isn't a Sunday and isn't lesser than the current date.
<input name="date" data-validate="required" type="date" data-role="calendarpicker" data-locale="fr-FR" data-format="%Y-%m-%d" placeholder="Choisissez une date" />
I just want to know how and if it's possible to write something like data-validate="myfunction()" to make the form behave like the predefined functions