def __init__(self, year=1997, month=1): SimpleDocument.__init__(self, bgcolor = PAGECOLOR) self.year = year self.month = month self.monthname = month_name[month] self.title = self.monthname + ' ' + str(self.year) self.ndays = mdays[month] now = time.strftime("%c", time.localtime(time.time())) self.append( '<P>', Font("Updated " + now, size = -1) ) self.append( Center( H(3,self.title) ) ) self.datetable = DateTable(cellpadding=6, cellspacing=2, border=3) self.jumper = '' for i in range(1, self.ndays+1): self.jumper = self.jumper + str(Href('#'+`month`+'-'+`i`, `i`)) + ' ' self.datetable.append(Day(self.year, self.month, i)) self.append( Center(self.jumper, html_escape='off') ) self.append('<P>') self.append( self.datetable )