3.2.0

Here Is A Calendar That Works With ActiveWidgets

Several times I have seen messages noting that some calendar javascripts will not work with ActiveWidgets (variables named the same).

I am using Tigra Calendar by Software Complex and it seems to work fine: www.softcomplex.com

ericj
October 12,
Using JavaScript Calendar: http://www.dynarch.com/projects/calendar/

<html>
<head>
  <script src="/ActiveWidgets/runtime/lib/aw.js"></script>
  <script type="text/javascript" src="/jscalendar/calendar.js"></script>
  <script type="text/javascript" src="/jscalendar/lang/calendar-en.js"></script>
  <script type="text/javascript" src="/jscalendar/calendar-setup.js"></script>
  <link href="/ActiveWidgets/runtime/styles/aqua/aw.css" rel="stylesheet"></link>
  <link rel="stylesheet" type="text/css" media="all" href="/jscalendar/calendar-blue2.css" title="blue2" />
  <style>
    #TimeLabel { left:  10px;  top: 10px; }
    #TimeField { left:  50px;  top: 10px; }
    #TimeImg   { left: 100px;  top: 10px; }
  </style>
</head>
<body>
<input type="hidden" value="" name="TimeHidden" id="TimeHidden" />

<script type="text/javascript">
  var time_lab = new AW.UI.Label;
  time_lab.setId("TimeLabel");
  time_lab.setControlText("Date/Time:");
  document.write(time_lab);

  var time_input = new AW.UI.Input;
  time_input.setId("TimeField");
  time_input.setControlText("2006-10-12 01:00");
  document.write(time_input);

  var time_img = new AW.UI.Label;
  time_img.setId("TimeImg");
  time_img.setControlText("");
  time_img.setControlImage("search");
  document.write(time_img);

  function time_update(cal) {
    var date = cal.date.print("%Y-%m-%d %H:%M");
    time_input.setControlText(date);
    time_input.refresh();
  }

  Calendar.setup({
    inputField          : "TimeHidden",
    button              : "TimeImg",
    eventName           : "click",
    ifFormat            : "%Y-%m-%d %H:%M",
    daFormat            : "%Y-%m-%d %H:%M",
    singleClick         : false,
    firstDay            : 0,
    weekNumbers         : false,
    showsTime           : true,
    timeFormat          : 24,
    electric            : true,
    showOthers          : true,
    timeInterval        : 15,
    onUpdate            : time_update
   });
</script>
</body>
</html>
Mike
October 12,

This topic is archived.

See also:


Back to support forum