If I use a datepicker field on a contour form and don't use the datepicker to enter the date and enter it manually it allows me to enter garbage i.e 1315 as the date - this text isn't passed in the email generated by the form using Contour Contrib but Contour doesn't disallow an invalid date to be entered in the field.
Is this a bug within Contour and what can I do about it?
Have you disabled the date picker or how should it be understood? If it's just a plain text field I suppose there's not much to do about it...But I'm probably missing something? :)
I have not disabled the date picker, it's as it is "out-of-the-box" and if the date picker is used to select the date then the content of the field is correct but it is possible to manually type in the field that the date picker fills in - and as it's a plain text field that the picker fills in, anything can be entered.
Datepicker field validation
If I use a datepicker field on a contour form and don't use the datepicker to enter the date and enter it manually it allows me to enter garbage i.e 1315 as the date - this text isn't passed in the email generated by the form using Contour Contrib but Contour doesn't disallow an invalid date to be entered in the field.
Is this a bug within Contour and what can I do about it?
Hi Steve
Have you disabled the date picker or how should it be understood? If it's just a plain text field I suppose there's not much to do about it...But I'm probably missing something? :)
/Jan
I have not disabled the date picker, it's as it is "out-of-the-box" and if the date picker is used to select the date then the content of the field is correct but it is possible to manually type in the field that the date picker fills in - and as it's a plain text field that the picker fills in, anything can be entered.
Hi Steve
Aaah, yes of course - Get it now.
Perhaps you can add a pattern attribute to the date picker input type? This requires that you modify the source code Contour generates though but you can learn more about that here https://our.umbraco.org/projects/umbraco-pro/contour/documentation/Developer/Custom-Markup/ and then you can perhaps use one of these patterns http://html5pattern.com/Dates
Hope this helps.
/Jan
is working on a reply...