check if data is before or after another date javascript code example
Example: how check if a form date is before today javascript
var Startdate = new Date(document.getElementById("Insert ID here").value)
var now = new Date();
if (before < now) {
// selected date is in the past
}