Expand Input Date Calendar (browser Native)
Is it possible to expand a native browser calendar.. ..just like you're actually clicking on it? I tried simulating a click
Solution 1:
There is no need to trigger any event to display Native DatePicker/TimePicker. If browser supports HTML5 input type date/time, then it will open native DatePicker/TimePicker. Check this example
Solution 2:
May be you can use this hack -
HTML
<input id="calendar" type="date"></input>
<input class="button" type="button" value="Click"/>
CSS
#calendar {
position: absolute;
opacity: 0;
right: 15px;
}
.button{
float: right;
}
Uses CSS to position the datepicker just over the btn. The datepicker is hidden using Opacity: 0 so users can see your button.
Post a Comment for "Expand Input Date Calendar (browser Native)"