// include to configure calendar behaviour
echo ('
  <script type="text/javascript">
    Calendar.setup(
      {
        inputField  : "ff_elem647",    // ID of the input field
        ifFormat    : "%A, %d %B, %Y", // the date format
        button      : "ff_elem648",    // ID of the button
        singleClick : true,            // close popup on single click
        firstDay    : 1,               // Monday as first day of the week
        range       : [2006,2016]      // min and max years allowed
      }
    );
    Calendar.setup(
      {
        inputField  : "ff_elem651",    // ID of the input field
        ifFormat    : "%A, %d %B, %Y", // the date format
        button      : "ff_elem652",    // ID of the button
        singleClick : true,            // close popup on single click
        firstDay    : 1,               // Monday as first day of the week
        range       : [2006,2016]      // min and max years allowed
      }
    );
  </script>
');