You are not logged in Log in Join
You are here: Home » Members » Ty Sarna's Zope.Org Page » Calendar Tag » swpackage_view

Log in
Name

Password

 
 

Calendar Tag

Calendar DTML Tag

Renders a calendar user interface. The template code is executed to render the individual day cells. The template is called with several predefined variables.

See author and license information at the end of this file.

Usage:

    <!--#calendar [args]-->
      template code
    <!--#/calendar-->

Variables

date (date)
date to be rendered by the template.
mode (string day, week, or month)
mode in which the display is currently operating.
firstday (bool)
true if this is the first time the template is being rdnered for this calendar, false otherwise.
linkDate(date[, mode]) (callback function)
returns a url for the current page with the current calendar set to a the given date and in the given mode (mode defaults to day). This is for the convenience of the rendering template for things like liking from a given day in the month mode to the day-mode display for that day.
getCalendar(name[, defval]): (callback function)
Returns the given rendering property of the calendar, or defval (default NULL) is there is no such property.
setCalendar(name, val): (callback function)
Sets the given rendering property of the calendar.

Properties

leftfgcolor
color of text in left part of header (where the date or date range is shown). Default is the overall bgcolor.
leftbgcolor
background color on left part of header. Default is black (000000).
middlebgcolor
background color of middle of header (where the day/week/month buttons are). Defaults to overall bgcolor.
rightbgcolor
background color of right part of header (where arrows are). Defaults to overall bgcolor.
cellbgcolor
background color of current day (defauilts to overall bgcolor).

align-- day's table horizontal cell alignment, default none.

valign
day's table vertical cell alignment, default none.
left (string)
text of left of header. Defaults to date or date range.
middle (string)
text of middle of header. Defaults to the mode buttons.
right (string)
text of right of header. Defaults to arrows with rightmiddle inbetween.
rightmiddle (string)
text between arrows in right of header. Defaults to day buttons, week number, or blank, depending on mode.
daynames
in week and month modes, the name of the day headers. ignored in day mode. Value is either None (don't display headers), a 7 character string (default, value SMTWTFS), or a 7 element list or tuple containing string names for the days.
bordercolor
the color of the border and lines drawn around the calendar elements. Defaults to 000000.
spacing
the spacing between the calendar cells. This also controls the width of the border drawn in bordercolor. Defaults to 2.
padding
the padding within the calendar cells. Defaults to 4.

Arguments

name (string)
name of the calendar instance, used for the query string names. Default is calendar. Two instances on the same page may share the same name, but if so their controls will be locked together -- they will display the same date and mode always.
mode (string day, week, or month)
default mode to display in if unspecified by user.
date (string expr)
if supplied, evaluates to the date to show by default.
bgcolor (string)
background color. Foreground color is always black. Default white (ffffff).
Latest Release: 0.9.0
Last Updated: 1999-09-30 15:05:14
Author: ZopeOrgSite
Categories: DTML Extension, Zope Product
Maturity: Stable

Available Releases

Version Maturity Platform Released
0.9.0 Stable   1999-09-30 15:05:14
  Calendar-0-9-0.tgz (6 K) All