DHTMLX Docs & Samples Explorer

Change parent

  • March2013
  • w
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • Su
  • 9
  • 25
  • 26
  • 27
  • 28
  • 1
  • 2
  • 3
  • 10
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 12
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 13
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 14
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 16:00
Source
<link rel="stylesheet" type="text/css" href="../../codebase/dhtmlxcalendar.css">
    <link rel="stylesheet" type="text/css" href="../../codebase/skins/dhtmlxcalendar_dhx_skyblue.css">
    <script src="../../codebase/dhtmlxcalendar.js"></script>
    <style>
        td.td {
            text-align: center;
        }
        div#calendarHere1, div#calendarHere2 {
            position: relative;
            width: 200px;
            height: 250px;
        }
    </style>
    <script>
var myCalendar;
function doOnLoad() {
    myCalendar = new dhtmlXCalendarObject("calendarHere1");
    myCalendar.setDate(new Date(2013, 2, 1, 16, 0));
    myCalendar.show();
}
</script> <table border="1"> <tr> <td class="td"><input type="button" value="Show here" onclick="myCalendar.setParent('calendarHere1');"></td> <td class="td"><input type="button" value="Show here" onclick="myCalendar.setParent('calendarHere2');"></td> </tr> <tr> <td class="td"><div id="calendarHere1" style="position:relative;height:250px;"></div></td> <td class="td"><div id="calendarHere2" style="position:relative;height:250px;"></div></td> </tr> </table>