I have a simple input like :
Enter Payment Date : <input type="date" name="date" required><br/><br/>
Now I want to restrict the user from selecting a date before the current date. I checked the attributes of the date input and found that I can set a min and max date. But the min attribute requires me to specify a particular date like min="2017-08-06"
. But I want it to be system's current date. Because if I set the min date as 2017-08-06 and the user uses the app later on 2017-08-20, then the user can choose a date like 2017-08-15 or so, which I don't want to. I want the user to be able to choose dates from the present date on which he/she is using the app.
Is there any way I can do that using this input field?
Sorry, this is a long explanation, I wanted to clear it out.