Is there a way to disable future time input using
<input type='time'>
I want the time to be restricted from 9 am to 3 pm.
Is there a way to disable future time input using
<input type='time'>
I want the time to be restricted from 9 am to 3 pm.
Use min
, max
and pattern
attributes:
<form action="/action_page.php">
Select a time:
<input type="time" name="usr_time" min="09:00" max="15:00" pattern="(09|1[0-5]):[0-5]\d">
<input type="submit">
</form>