<!--
  function dateStuff()
   {
    TMonth = new Array('January','February','March','April','May','June','July','August','September','October','November','December');
    TDay = new Array('Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday');
    TDate = new Date();
    CurDay = TDate.getDay();
    CurMonth = TDate.getMonth();
    Month = TMonth[CurMonth];
    Day = TDay[CurDay];
    NDay = TDate.getDate();
    CurYear = TDate.getYear();

    //alert (CurYear)
    if (CurYear < 1900)
      //Year = "19" + CurYear;
      Year = CurYear + 1900;
    else Year = CurYear;

    document.write(Day + ", " + Month + " " + NDay + ", " + Year);
   }

  function timeStuff() {
    var today = new Date();
    var display= today.toLocaleString();
    // var currTime = hour(today) + ":" + minute(today) + ":" + second(today);
    document.write(display);
   }

  function runClock() {
    theTime = window.setTimeout("runClock()", 1000);
    timeStuff();
    status=display;
   }

//--------------------------------------------------------------
// Function:    daysInMonth(iMonth, iYear)
// Description: Returns the number of days in a given month.
//              The month parameter is 0 relative like that of
//              the Date object, so January = 0 and December =
//              11.  If the month parameter is 1 (February) the
//              year parameter must be supplied as a call is
//              made to the isLeapYear() function using the
//              year.
// Author:      Steve Crane (MCSD)
//              stevec@netlane.com
//--------------------------------------------------------------
function daysInMonth(iMonth, iYear) {
  if (iMonth < 0 || iMonth > 11)
    return 0;

  if (iMonth == 1)
    return (28 + isLeapYear(iYear));
  else
    if (iMonth == 3 || iMonth == 5 || iMonth == 8 || iMonth == 10)
      return (30);
    else
      return (31);
}

//--------------------------------------------------------------
// Function:    isDate(sDate)
// Description: Tests the sDate string to see whether it is a
//              valid date.  sDate must be in d/m/yy or 
//              d/m/ccyy format.
// Author:      Steve Crane (MCSD)
//              stevec@netlane.com
//--------------------------------------------------------------
function isDate(sDate) {
  var aiDays = new Array(31,28,31,30,31,30,31,31,30,31,30,31);
  var iDay;
  var iMonth;
  var iYear;

  if (sDate.substring(1, 2) == '/') {
    iDay = parseInt(sDate.substring(0, 1), 10);
    if (sDate.substring(3, 4) == '/') {
      iMonth = parseInt(sDate.substring(2, 3), 10);
      iYear = parseInt(sDate.substring(4, 8), 10);
    }
    else {
      iMonth = parseInt(sDate.substring(2, 4), 10);
      iYear = parseInt(sDate.substring(5, 9), 10);
    }
  }
  else {
    iDay = parseInt(sDate.substring(0, 2), 10);
    if (sDate.substring(4, 5) == '/') {
      iMonth = parseInt(sDate.substring(3, 4), 10);
      iYear = parseInt(sDate.substring(5, 9), 10);
    }
    else {
      iMonth = parseInt(sDate.substring(3, 5), 10);
      iYear = parseInt(sDate.substring(6, 10), 10);
    }
  }
  
  if (iDay < 1 || iMonth < 1 || iYear < 0)
    return 0;
    
  if (iMonth > 12)
    return 0;

  iYear += iYear < 100 ? iYear > 10 ? 1900 : 2000 : 0;
  aiDays[1] += (iYear % 4 ? 0 : iYear % 100 ? 1 : iYear % 400 ?
    iYear == 200 ? 1 : 0 : 1);

  return (iDay <= aiDays[iMonth - 1]);
}

//--------------------------------------------------------------
// Function:    isLeapYear(iYear)
// Description: Tests the iYear argument to see whether it is
//              a leap year.
// Author:      Steve Crane (MCSD)
//              stevec@netlane.com
//--------------------------------------------------------------
function isLeapYear(iYear) {
  return (iYear % 4 ? 0 : iYear % 100 ? 1 : iYear % 400 ? iYear == 200 ? 1 : 0 : 1);
}

//--------------------------------------------------------------
// Function:     WeekDate(vDate, ucDay)
// Description:  Returns the date of the day specified by ucDay
//               of the week that vDate falls in.  ucDay must be
//               in the range 1 (Sunday) to 7 (Saturday). A call
//               of WeekDate(Date(), 2) will return the date of
//               Monday in the current week.
// Author:       Steve Crane (MCSD)
//               stevec@netlane.com
//--------------------------------------------------------------
// Function WeekDate(vDate, ucDay) {
  // WeekDate = DateAdd("d", -(WeekDay(vDate) - ucDay), vDate);
  // }
// End Function

// -->
