Home>

I make a simple reservation form in php.
In the date input field, select the date after 3 days.

Error message

It worked on PC and Android,
It does not work well with safari and all dates can be selected.

Applicable source code
<input type = "date" name = "〇〇" min = "<? php echo date ('Ym-d', strtotime ('+ 3 day'));?>">
Tried

I found Moment.js but I didn't know how to write it.

  • Answer # 1

    I can't confirm it because I don't have an iOS device at hand. Isn't the used Safari supporting the min attribute of date?

    min attribute

      

    Some browsers do not support date input fields that specify date in the type attribute of the input element.