JSFiddle - React, Tailwind, and code Playground
by jquerybyexample
HTML
<link rel="stylesheet" href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.17/themes/base/jquery-ui.css">
<link rel="stylesheet" href="http://static.jquery.com/ui/css/demo-docs-theme/ui.theme.css">
<br/>
From: <input type="text" id="txtFromDate" />
To: <input type="text" id="txtToDate" />
CSS
body
{
font-size:8pt;
font-family:Verdana;
padding: 5px;
}
JavaScript
$(document).ready(function(){
$("#txtFromDate").datepicker({
numberOfMonths: 2,
onSelect: function(selected) {
$("#txtToDate").datepicker("option","minDate", selected)
}
});
$("#txtToDate").datepicker({
numberOfMonths: 2,
onSelect: function(selected) {
$("#txtFromDate").datepicker("option","maxDate", selected)
}
});
});