% Option Explicit '########################################################### '## COPYRIGHT (C) 2002-2008, Metasun Software Corp. '## '## For licensing details, lease read the license.txt file '## included with MetaTraffic or located at: '## http://www.metasun.com/products/metatraffic/license.asp '## '## All copyright notices regarding MetaTraffic '## must remain intact in the scripts and in the '## outputted HTML. All text and logos with '## references to Metasun or MetaTraffic must '## remain visible when the pages are viewed on '## the internet or intranet. '## '## For support, please visit http://www.metasun.com '## and use the support forum. '########################################################### %> <% Dim strClass, intDayLoop Dim strShortDate : strShortDate = aryMTConfig(10) Dim strFormName : strFormname = Request.Querystring("name") Dim datSelected : datSelected = Request.Querystring("sdate") Dim datCurrent : datCurrent = Request.Querystring("cdate") If Isdate(datSelected) = False Then datSelected = Date() End If If Isdate(datCurrent) = False Then datCurrent = datSelected End If datSelected = Cdate(datSelected) datCurrent = Cdate(datCurrent) Dim datToday : datToday = Date() Dim datMonth : datMonth = Month(datCurrent) Dim datMonthName : datMonthName = Monthname(datMonth) Dim datYear : datYear = Year(datCurrent) Dim datNextMonth : datNextMonth = Month(DateAdd("m", 1, datCurrent)) Dim datNextMonthYear : datNextMonthYear = Year(DateAdd("m", 1, datCurrent)) Dim intDaysInMonth : intDaysInMonth = Day(DateSerial(Year(datCurrent), Month(datCurrent) + 1, 0)) Dim intStartWeekday : intStartWeekday = Weekday(DateAdd("d", (1 - Day(datCurrent)), datCurrent), 1) Dim intEndWeekday : intEndWeekday = Weekday(DateAdd("d", intDaysInMonth, DateAdd("d", (0 - Day(datCurrent)), datCurrent)), 1) Dim intWeekdayPos : intWeekdayPos = 0 %>
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
" Next End If For intDayLoop = 1 to intDaysInMonth intWeekdayPos = intWeekdayPos + 1 ' START NEW ROW IF BEGINNING OF WEEK If intWeekdayPos Mod 7 = 1 Then Response.Write " | ||||||
" Response.Write "" Response.Write intDayLoop & " | " ' CLOSE OFF ROW IF END OF WEEK If intWeekdayPos Mod 7 = 0 Then Response.Write "" Next End If Response.Write " |