- <input type="text" size="10" id="to" name="to" value="[% to_placed_on %]" />
- <img src="[% themelang %]/lib/calendar/cal.gif" id="openCalendarTo" style="cursor: pointer;" alt="Show Calendar" />
- <script type="text/javascript">
- // return true if the date is blocked.
- function disable_from(date) {var limit = get_Calendar_limit(date,'to' ); return (limit && limit < date);} // true or false
- function disable_to (date) {var limit = get_Calendar_limit(date,'from'); return (limit && limit > date);} // true or false
- Calendar.setup({
- inputField : "from",
- ifFormat : "[% DHTMLcalendar_dateformat %]",
- button : "openCalendarFrom",
- disableFunc : disable_from,
- dateStatusFunc : disable_from
- });
- Calendar.setup({
- inputField : "to",
- ifFormat : "[% DHTMLcalendar_dateformat %]",
- button : "openCalendarTo",
- disableFunc : disable_to,
- dateStatusFunc : disable_to
- });
- </script>