DHTMLX Docs & Samples Explorer

Attach Calendar to text input

You can attach calendar to input object.

Click in a text fild

Source
<link rel="STYLESHEET" type="text/css" href="../../codebase/dhtmlxcalendar.css">
<script>
window.dhx_globalImgPath = "../../codebase/imgs/";
</script> <script src="../../codebase/dhtmlxcommon.js"></script> <script src="../../codebase/dhtmlxcalendar.js"></script> <script>
var cal1,
cal2,
mCal,
mDCal,
newStyleSheet;
var dateFrom = null;
var dateTo = null;
window.onload = function() {
    cal1 = new dhtmlxCalendarObject('calInput1');
}
</script> <table > <tr> <td valign="top"><strong>Click in a text fild</strong><br /> <input type="text" id="calInput1" style="width: 200px; font-size:12px;" readonly="true"> </td> </tr> </table> </table> <br>