root/trunk/deployment/webpublic/webapp/resources/demoskins/SoEDepartmental/default/default/default.xsl

Revision 1226 (checked in by johnsa, 6 years ago)

personal client

- more rdate work

general web client cleanup

Line 
1 <?xml version="1.0" encoding="UTF-8"?>
2 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
3 <xsl:output
4   method="xhtml"
5   indent="no"
6   media-type="text/html"
7   doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
8   doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"
9   standalone="yes"
10   omit-xml-declaration="yes"/>
11
12 <!-- =========================================================
13
14         DEMONSTRATION "DEPARTMENTAL" CALENDAR STYLESHEET
15
16      This stylesheet is for the "soe" (School of Engineering)
17      calendar suite; it is an example of a departmental skin.
18
19      This skin, along with the preferences for the Calendar
20      Suite owner, differs from the main public skin (default.xsl) in the
21      following ways:
22        - different header, title, and footer
23        - default layout = list view (rather than calendar grid)
24        - different color scheme
25
26      Otherwise, for the sake of demonstration, we've left most of the
27      functionality of the public client in place.
28
29      For detailed instructions on how to work with the XSLT
30      stylesheets included with this distribution, please see the
31      Bedework Design Guide at
32      http://www.bedework.org/bedework/update.do?artcenterkey=24
33
34 ===============================================================  -->
35
36 <!-- **********************************************************************
37   Copyright 2006 Rensselaer Polytechnic Institute. All worldwide rights reserved.
38
39   Redistribution and use of this distribution in source and binary forms,
40   with or without modification, are permitted provided that:
41      The above copyright notice and this permission notice appear in all
42       copies and supporting documentation;
43
44       The name, identifiers, and trademarks of Rensselaer Polytechnic
45       Institute are not used in advertising or publicity without the
46       express prior written permission of Rensselaer Polytechnic Institute;
47
48   DISCLAIMER: The software is distributed" AS IS" without any express or
49   implied warranty, including but not limited to, any implied warranties
50   of merchantability or fitness for a particular purpose or any warrant)'
51   of non-infringement of any current or pending patent rights. The authors
52   of the software make no representations about the suitability of this
53   software for any particular purpose. The entire risk as to the quality
54   and performance of the software is with the user. Should the software
55   prove defective, the user assumes the cost of all necessary servicing,
56   repair or correction. In particular, neither Rensselaer Polytechnic
57   Institute, nor the authors of the software are liable for any indirect,
58   special, consequential, or incidental damages related to the software,
59   to the maximum extent the law permits. -->
60
61   <!-- ================================= -->
62   <!--  DEMO PUBLIC CALENDAR STYLESHEET  -->
63   <!-- ================================= -->
64
65   <!-- URL of resources common to all bedework apps (javascript, images) -->
66   <xsl:variable name="resourceCommons">../../../bedework-common</xsl:variable>
67
68   <!-- DEFINE INCLUDES -->
69   <!-- cannot use the resourceCommons variable in xsl:include paths -->
70   <xsl:include href="../../../bedework-common/default/default/errors.xsl"/>
71   <xsl:include href="../../../bedework-common/default/default/messages.xsl"/>
72
73   <!-- DEFINE GLOBAL CONSTANTS -->
74
75   <!-- URL of the XSL template directory -->
76   <!-- The approot is an appropriate place to put
77        included stylesheets and xml fragments. These are generally
78        referenced relatively (like errors.xsl and messages.xsl above);
79        this variable is here for your convenience if you choose to
80        reference it explicitly.  It is not used in this stylesheet, however,
81        and can be safely removed if you so choose. -->
82   <xsl:variable name="appRoot" select="/bedework/approot"/>
83
84   <!-- URL of html resources (images, css, other html); by default this is
85        set to the application root -->
86   <xsl:variable name="resourcesRoot" select="/bedework/approot"/>
87
88   <!-- Properly encoded prefixes to the application actions; use these to build
89        urls; allows the application to be used without cookies or within a portal.
90        These urls are rewritten in header.jsp and simply passed through for use
91        here. Every url includes a query string (either ?b=de or a real query
92        string) so that all links constructed in this stylesheet may begin the
93        query string with an ampersand. -->
94   <xsl:variable name="setup" select="/bedework/urlPrefixes/setup"/>
95   <xsl:variable name="setSelection" select="/bedework/urlPrefixes/main/setSelection"/>
96   <xsl:variable name="fetchPublicCalendars" select="/bedework/urlPrefixes/calendar/fetchPublicCalendars"/>
97   <xsl:variable name="setViewPeriod" select="/bedework/urlPrefixes/main/setViewPeriod"/>
98   <xsl:variable name="eventView" select="/bedework/urlPrefixes/event/eventView"/>
99   <xsl:variable name="addEventRef" select="/bedework/urlPrefixes/event/addEventRef"/>
100   <xsl:variable name="export" select="/bedework/urlPrefixes/misc/export/a/@href"/>
101   <xsl:variable name="search" select="/bedework/urlPrefixes/search/search"/>
102   <xsl:variable name="search-next" select="/bedework/urlPrefixes/search/next"/>
103   <xsl:variable name="mailEvent" select="/bedework/urlPrefixes/mail/mailEvent"/>
104   <xsl:variable name="showPage" select="/bedework/urlPrefixes/main/showPage"/>
105   <xsl:variable name="stats" select="/bedework/urlPrefixes/stats/stats"/>
106
107   <!-- URL of the web application - includes web context -->
108   <xsl:variable name="urlPrefix" select="/bedework/urlprefix"/>
109
110   <!-- Other generally useful global variables -->
111   <xsl:variable name="privateCal">/ucal</xsl:variable>
112   <xsl:variable name="prevdate" select="/bedework/previousdate"/>
113   <xsl:variable name="nextdate" select="/bedework/nextdate"/>
114   <xsl:variable name="curdate" select="/bedework/currentdate/date"/>
115
116
117   <!-- MAIN TEMPLATE -->
118   <xsl:template match="/">
119     <html>
120       <head>
121         <title>School of Engineering: Example Bedework Departmental Calendar Suite</title>
122         <meta content="text/html;charset=utf-8" http-equiv="Content-Type" />
123         <link rel="stylesheet" type="text/css" href="{$resourcesRoot}/default/default/soe.css" />
124         <link rel="stylesheet" href="{$resourcesRoot}/default/default/subColors.css"/>
125         <!-- load javascript -->
126         <xsl:if test="/bedework/page='calendarList'">
127           <script type="text/javascript" src="{$resourceCommons}/javascript/dojo/dojo.js">&#160;</script>
128           <script type="text/javascript" src="{$resourcesRoot}/resources/javascript/bedework.js">&#160;</script>
129         </xsl:if>
130         <!-- address bar icon -->
131         <link rel="icon" type="image/ico" href="{$resourcesRoot}/images/bedework.ico" />
132       </head>
133       <body>
134         <xsl:call-template name="headBar"/>
135         <xsl:if test="/bedework/error">
136           <div id="errors">
137             <xsl:apply-templates select="/bedework/error"/>
138           </div>
139         </xsl:if>
140         <xsl:call-template name="tabs"/>
141         <xsl:call-template name="navigation"/>
142         <xsl:call-template name="searchBar"/>
143         <xsl:choose>
144           <xsl:when test="/bedework/page='event'">
145             <!-- show an event -->
146             <xsl:apply-templates select="/bedework/event"/>
147           </xsl:when>
148           <xsl:when test="/bedework/page='showSysStats'">
149             <!-- show system stats -->
150             <xsl:call-template name="stats"/>
151           </xsl:when>
152           <xsl:when test="/bedework/page='calendarList'">
153             <!-- show a list of all calendars -->
154             <xsl:apply-templates select="/bedework/calendars"/>
155           </xsl:when>
156           <xsl:when test="/bedework/page='searchResult'">
157             <!-- display search results -->
158             <xsl:call-template name="searchResult"/>
159           </xsl:when>
160           <xsl:otherwise>
161             <!-- otherwise, show the eventsCalendar -->
162             <!-- main eventCalendar content -->
163             <xsl:choose>
164               <xsl:when test="/bedework/periodname='Day'">
165                 <xsl:call-template name="listView"/>
166               </xsl:when>
167               <xsl:when test="/bedework/periodname='Week' or /bedework/periodname=''">
168                 <xsl:choose>
169                   <xsl:when test="/bedework/appvar[key='weekViewMode']/value='cal'">
170                     <xsl:call-template name="weekView"/>
171                   </xsl:when>
172                   <xsl:otherwise>
173                     <xsl:call-template name="listView"/>
174                   </xsl:otherwise>
175                 </xsl:choose>
176               </xsl:when>
177               <xsl:when test="/bedework/periodname='Month'">
178                 <xsl:choose>
179                   <xsl:when test="/bedework/appvar[key='monthViewMode']/value='list'">
180                     <xsl:call-template name="listView"/>
181                   </xsl:when>
182                   <xsl:otherwise>
183                     <xsl:call-template name="monthView"/>
184                   </xsl:otherwise>
185                 </xsl:choose>
186               </xsl:when>
187               <xsl:otherwise>
188                 <xsl:call-template name="yearView"/>
189               </xsl:otherwise>
190             </xsl:choose>
191           </xsl:otherwise>
192         </xsl:choose>
193         <!-- footer -->
194         <xsl:call-template name="footer"/>
195       </body>
196     </html>
197   </xsl:template>
198
199   <!--==== HEADER TEMPLATES and NAVIGATION  ====-->
200   <!-- these templates are separated out for convenience and to simplify the default template -->
201
202   <xsl:template name="headBar">
203     <div id="headBar">
204       <div id="bedeworkLogo">
205         <a href="/bedework/">
206           <img src="{$resourcesRoot}/images/soecal/soeBedeworkLogo.gif" width="296" height="69" border="0" alt="Bedework" align="right"/>
207         </a>
208       </div>
209       <h1>Example Departmental Calendar Suite</h1>
210       <!--<ul id="schoolLinks">
211         <li><a href="{$privateCal}">Personal Calendar</a></li>
212         <li><a href="http://www.yourschoolhere.edu">School Home</a></li>
213         <li><a href="http://www.bedework.org/">Other Link</a></li>
214         <li>
215           <a href="http://helpdesk.rpi.edu/update.do?catcenterkey=51">
216             Example Calendar Help
217           </a>
218         </li>
219       </ul> -->
220     </div>
221     <!--  Turn off the date range table for this departmental view -->
222     <!--<table id="curDateRangeTable"  cellspacing="0">
223       <td class="sideBarOpenCloseIcon">
224         &#160; -->
225         <!--
226         we may choose to implement calendar selection in the public calendar
227         using a sidebar; leave this comment here for now.
228         <xsl:choose>
229           <xsl:when test="/bedework/appvar[key='sidebar']/value='closed'">
230             <a href="?setappvar=sidebar(opened)">
231               <img alt="open sidebar" src="{$resourcesRoot}/resources/sideBarArrowOpen.gif" width="21" height="16" border="0" align="left"/>
232             </a>
233           </xsl:when>
234           <xsl:otherwise>
235             <a href="?setappvar=sidebar(closed)">
236               <img alt="close sidebar" src="{$resourcesRoot}/resources/sideBarArrowClose.gif" width="21" height="16" border="0" align="left"/>
237             </a>
238           </xsl:otherwise>
239         </xsl:choose>-->
240       <!-- </td>
241       <td class="date">
242         <xsl:choose>
243           <xsl:when test="/bedework/page='event'">
244             Event Information
245           </xsl:when>
246           <xsl:when test="/bedework/page='showSysStats' or
247                           /bedework/page='calendars'">
248             &#160;
249           </xsl:when>
250           <xsl:otherwise>
251             <xsl:value-of select="/bedework/firstday/longdate"/>
252             <xsl:if test="/bedework/periodname!='Day'">
253               -
254               <xsl:value-of select="/bedework/lastday/longdate"/>
255             </xsl:if>
256           </xsl:otherwise>
257         </xsl:choose>
258       </td>
259       <td class="rssPrint">
260         <a href="javascript:window.print()" title="print this view">
261           <img alt="print this view" src="{$resourcesRoot}/images/std-print-icon.gif" width="20" height="14" border="0"/> print
262         </a>
263         <a class="rss" href="{$setSelection}&amp;setappvar=summaryMode(details)&amp;skinName=rss" title="RSS feed">RSS</a>
264       </td>
265     </table>-->
266   </xsl:template>
267
268   <xsl:template name="tabs">
269     <xsl:choose>
270       <xsl:when test="/bedework/page='eventscalendar'">
271         <table border="0" cellpadding="0" cellspacing="0" id="tabsTable">
272           <tr>
273             <td>
274               <xsl:choose>
275                 <xsl:when test="/bedework/periodname='Day'">
276                   <a href="{$setViewPeriod}&amp;viewType=dayView&amp;date={$curdate}"><img src="{$resourcesRoot}/images/std-tab-day-on.gif" width="91" height="20" border="0" alt="DAY"/></a>
277                 </xsl:when>
278                 <xsl:otherwise>
279                   <a href="{$setViewPeriod}&amp;viewType=dayView&amp;date={$curdate}"><img src="{$resourcesRoot}/images/std-tab-day-off.gif" width="91" height="20" border="0" alt="DAY"/></a>
280                 </xsl:otherwise>
281               </xsl:choose>
282             </td>
283             <td>
284               <xsl:choose>
285                 <xsl:when test="/bedework/periodname='Week' or /bedework/periodname=''">
286                   <a href="{$setViewPeriod}&amp;viewType=weekView&amp;date={$curdate}"><img src="{$resourcesRoot}/images/std-tab-week-on.gif" width="92" height="20" border="0" alt="WEEK"/></a>
287                  </xsl:when>
288                 <xsl:otherwise>
289                   <a href="{$setViewPeriod}&amp;viewType=weekView&amp;date={$curdate}"><img src="{$resourcesRoot}/images/std-tab-week-off.gif" width="92" height="20" border="0" alt="WEEK"/></a>
290                  </xsl:otherwise>
291               </xsl:choose>
292             </td>
293             <td>
294               <xsl:choose>
295                 <xsl:when test="/bedework/periodname='Month'">
296                   <a href="{$setViewPeriod}&amp;viewType=monthView&amp;date={$curdate}"><img src="{$resourcesRoot}/images/std-tab-month-on.gif" width="90" height="20" border="0" alt="MONTH"/></a>
297                 </xsl:when>
298                 <xsl:otherwise>
299                   <a href="{$setViewPeriod}&amp;viewType=monthView&amp;date={$curdate}"><img src="{$resourcesRoot}/images/std-tab-month-off.gif" width="90" height="20" border="0" alt="MONTH"/></a>
300                 </xsl:otherwise>
301               </xsl:choose>
302             </td>
303             <td>
304               <xsl:choose>
305                 <xsl:when test="/bedework/periodname='Year'">
306                   <a href="{$setViewPeriod}&amp;viewType=yearView&amp;date={$curdate}"><img src="{$resourcesRoot}/images/std-tab-year-on.gif" width="92" height="20" border="0" alt="YEAR"/></a>
307                 </xsl:when>
308                 <xsl:otherwise>
309                   <a href="{$setViewPeriod}&amp;viewType=yearView&amp;date={$curdate}"><img src="{$resourcesRoot}/images/std-tab-year-off.gif" width="92" height="20" border="0" alt="YEAR"/></a>
310                 </xsl:otherwise>
311               </xsl:choose>
312             </td>
313             <td class="rssPrint">
314               <a href="javascript:window.print()" title="print this view">
315                 <img alt="print this view" src="{$resourcesRoot}/images/std-print-icon.gif" width="20" height="14" border="0"/> print
316               </a>
317               <a class="rss" href="{$setup}&amp;setappvar=summaryMode(details)&amp;skinName=rss" title="RSS feed">RSS</a>
318             </td>
319           </tr>
320         </table>
321       </xsl:when>
322       <xsl:otherwise>
323         <table border="0" cellpadding="0" cellspacing="0" id="tabsTable">
324           <tr>
325             <td>
326               <a href="{$setViewPeriod}&amp;viewType=dayView&amp;date={$curdate}"><img src="{$resourcesRoot}/images/std-tab-day-off.gif" width="91" height="20" border="0" alt="DAY"/></a>
327             </td>
328             <td>
329               <a href="{$setViewPeriod}&amp;viewType=weekView&amp;date={$curdate}"><img src="{$resourcesRoot}/images/std-tab-week-off.gif" width="92" height="20" border="0" alt="WEEK"/></a>
330             </td>
331             <td>
332               <a href="{$setViewPeriod}&amp;viewType=monthView&amp;date={$curdate}"><img src="{$resourcesRoot}/images/std-tab-month-off.gif" width="90" height="20" border="0" alt="MONTH"/></a>
333             </td>
334             <td>
335               <a href="{$setViewPeriod}&amp;viewType=yearView&amp;date={$curdate}"><img src="{$resourcesRoot}/images/std-tab-year-off.gif" width="92" height="20" border="0" alt="YEAR"/></a>
336             </td>
337             <td class="rssPrint">
338               <a href="javascript:window.print()" title="print this view">
339                 <img alt="print this view" src="{$resourcesRoot}/images/std-print-icon.gif" width="20" height="14" border="0"/> print
340               </a>
341               <a class="rss" href="{$setSelection}&amp;setappvar=summaryMode(details)&amp;skinName=rss" title="RSS feed">RSS</a>
342             </td>
343           </tr>
344         </table>
345       </xsl:otherwise>
346     </xsl:choose>
347   </xsl:template>
348
349   <xsl:template name="navigation">
350     <table border="0" cellpadding="0" cellspacing="0" id="navigationBarTable">
351       <tr>
352         <td class="leftCell">
353           <a id="prevViewPeriod" href="{$setViewPeriod}&amp;date={$prevdate}"><img src="{$resourcesRoot}/images/std-arrow-left.gif" alt="previous" width="13" height="16" class="prevImg" border="0"/></a>
354           <a id="nextViewPeriod" href="{$setViewPeriod}&amp;date={$nextdate}"><img src="{$resourcesRoot}/images/std-arrow-right.gif" alt="next" width="13" height="16" class="nextImg" border="0"/></a>
355           <xsl:choose>
356             <xsl:when test="/bedework/periodname='Year'">
357               <xsl:value-of select="substring(/bedework/firstday/date,1,4)"/>
358             </xsl:when>
359             <xsl:when test="/bedework/periodname='Month'">
360               <xsl:value-of select="/bedework/firstday/monthname"/>, <xsl:value-of select="substring(/bedework/firstday/date,1,4)"/>
361             </xsl:when>
362             <xsl:when test="/bedework/periodname='Week'">
363               Week of <xsl:value-of select="substring-after(/bedework/firstday/longdate,', ')"/>
364             </xsl:when>
365             <xsl:otherwise>
366               <xsl:value-of select="/bedework/firstday/longdate"/>
367             </xsl:otherwise>
368           </xsl:choose>
369         </td>
370         <td class="todayButton">
371           <a href="{$setViewPeriod}&amp;viewType=todayView&amp;date={$curdate}">
372             <img src="{$resourcesRoot}/images/std-button-today-off.gif" width="54" height="22" border="0" alt="Go to Today" align="left"/>
373           </a>
374         </td>
375         <td align="right" class="gotoForm">
376           <form name="calForm" method="post" action="{$setViewPeriod}">
377              <table border="0" cellpadding="0" cellspacing="0">
378               <tr>
379                 <xsl:if test="/bedework/periodname!='Year'">
380                   <td>
381                     <select name="viewStartDate.month">
382                       <xsl:for-each select="/bedework/monthvalues/val">
383                         <xsl:variable name="temp" select="."/>
384                         <xsl:variable name="pos" select="position()"/>
385                         <xsl:choose>
386                           <xsl:when test="/bedework/monthvalues[start=$temp]">
387                             <option value="{$temp}" selected="selected">
388                               <xsl:value-of select="/bedework/monthlabels/val[position()=$pos]"/>
389                             </option>
390                           </xsl:when>
391                           <xsl:otherwise>
392                             <option value="{$temp}">
393                               <xsl:value-of select="/bedework/monthlabels/val[position()=$pos]"/>
394                             </option>
395                           </xsl:otherwise>
396                         </xsl:choose>
397                       </xsl:for-each>
398                     </select>
399                   </td>
400                   <xsl:if test="/bedework/periodname!='Month'">
401                     <td>
402                       <select name="viewStartDate.day">
403                         <xsl:for-each select="/bedework/dayvalues/val">
404                           <xsl:variable name="temp" select="."/>
405                           <xsl:variable name="pos" select="position()"/>
406                           <xsl:choose>
407                             <xsl:when test="/bedework/dayvalues[start=$temp]">
408                               <option value="{$temp}" selected="selected">
409                                 <xsl:value-of select="/bedework/daylabels/val[position()=$pos]"/>
410                               </option>
411                             </xsl:when>
412                             <xsl:otherwise>
413                               <option value="{$temp}">
414                                 <xsl:value-of select="/bedework/daylabels/val[position()=$pos]"/>
415                               </option>
416                             </xsl:otherwise>
417                           </xsl:choose>
418                         </xsl:for-each>
419                       </select>
420                     </td>
421                   </xsl:if>
422                 </xsl:if>
423                 <td>
424                   <xsl:variable name="temp" select="/bedework/yearvalues/start"/>
425                   <input type="text" name="viewStartDate.year" maxlength="4" size="4" value="{$temp}"/>
426                 </td>
427                 <td>
428                   <input name="submit" type="submit" value="go"/>
429                 </td>
430               </tr>
431             </table>
432           </form>
433         </td>
434         <td class="rightCell">
435         </td>
436       </tr>
437     </table>
438   </xsl:template>
439
440   <xsl:template name="searchBar">
441     <table width="100%" border="0" cellpadding="0" cellspacing="0" id="searchBarTable">
442        <tr>
443          <td class="leftCell">
444            <xsl:choose>
445              <xsl:when test="/bedework/selectionState/selectionType = 'calendar'">
446                Calendar: <xsl:value-of select="/bedework/selectionState/subscriptions/subscription/calendar/name"/>
447                <span class="link">[<a href="{$setSelection}">default view</a>]</span>
448              </xsl:when>
449              <xsl:when test="/bedework/selectionState/selectionType = 'search'">
450                Current search: <xsl:value-of select="/bedework/search"/>
451                <span class="link">[<a href="{$setSelection}">default view</a>]</span>
452              </xsl:when>
453              <xsl:when test="/bedework/selectionState/selectionType = 'subscription'">
454                Subscription: (not implemented yet)
455                <span class="link">[<a href="{$setSelection}">default view</a>]</span>
456              </xsl:when>
457              <xsl:when test="/bedework/selectionState/selectionType = 'filter'">
458                Filter: (not implemented yet)
459                <span class="link">[<a href="{$setSelection}">default view</a>]</span>
460              </xsl:when>
461              <xsl:otherwise><!-- view -->
462                View:
463                <form name="selectViewForm" method="post" action="{$setSelection}">
464                 <select name="viewName" onchange="submit()" >
465                   <xsl:for-each select="/bedework/views/view">
466                     <xsl:variable name="name" select="name"/>
467                     <xsl:choose>
468                       <xsl:when test="name=/bedework/selectionState/view/name">
469                         <option value="{$name}" selected="selected"><xsl:value-of select="name"/></option>
470                       </xsl:when>
471                       <xsl:otherwise>
472                         <option value="{$name}"><xsl:value-of select="name"/></option>
473                       </xsl:otherwise>
474                     </xsl:choose>
475                   </xsl:for-each>
476                 </select>
477               </form>
478               <span class="link"><a href="{$setSelection}">default view</a> | <a href="{$fetchPublicCalendars}">available calendars</a></span>
479              </xsl:otherwise>
480            </xsl:choose>
481          </td>
482          <td class="rightCell">
483             <xsl:if test="/bedework/page!='searchResult'">
484               <form name="searchForm" id="searchForm" method="post" action="{$search}">
485                 Search:
486                 <input type="text" name="query" size="15">
487                   <xsl:attribute name="value"><xsl:value-of select="/bedework/searchResults/query"/></xsl:attribute>
488                 </input>
489                 <input type="submit" name="submit" value="go"/>
490               </form>
491               <xsl:text> </xsl:text>
492             </xsl:if>
493             <xsl:choose>
494               <xsl:when test="/bedework/periodname='Day'">
495                 <img src="{$resourcesRoot}/images/std-button-listview-off.gif" width="46" height="21" border="0" alt="toggle list/calendar view"/>
496               </xsl:when>
497               <xsl:when test="/bedework/periodname='Year'">
498                 <img src="{$resourcesRoot}/images/std-button-calview-off.gif" width="46" height="21" border="0" alt="toggle list/calendar view"/>
499               </xsl:when>
500               <xsl:when test="/bedework/periodname='Month'">
501                 <xsl:choose>
502                   <xsl:when test="/bedework/appvar[key='monthViewMode']/value='list'">
503                     <a href="{$setup}&amp;setappvar=monthViewMode(cal)" title="toggle list/calendar view">
504                       <img src="{$resourcesRoot}/images/std-button-calview.gif" width="46" height="21" border="0" alt="toggle list/calendar view"/>
505                     </a>
506                   </xsl:when>
507                   <xsl:otherwise>
508                     <a href="{$setup}&amp;setappvar=monthViewMode(list)" title="toggle list/calendar view">
509                       <img src="{$resourcesRoot}/images/std-button-listview.gif" width="46" height="21" border="0" alt="toggle list/calendar view"/>
510                     </a>
511                   </xsl:otherwise>
512                 </xsl:choose>
513               </xsl:when>
514               <xsl:otherwise>
515                 <xsl:choose>
516                   <xsl:when test="/bedework/appvar[key='weekViewMode']/value='cal'">
517                     <a href="{$setup}&amp;setappvar=weekViewMode(list)" title="toggle list/calendar view">
518                       <img src="{$resourcesRoot}/images/std-button-listview.gif" width="46" height="21" border="0" alt="toggle list/calendar view"/>
519                     </a>
520                   </xsl:when>
521                   <xsl:otherwise>
522                     <a href="{$setup}&amp;setappvar=weekViewMode(cal)" title="toggle list/calendar view">
523                       <img src="{$resourcesRoot}/images/std-button-calview.gif" width="46" height="21" border="0" alt="toggle list/calendar view"/>
524                     </a>
525                   </xsl:otherwise>
526                 </xsl:choose>
527               </xsl:otherwise>
528             </xsl:choose>
529             <xsl:choose>
530               <xsl:when test="/bedework/periodname='Year' or
531                               (/bedework/periodname='Month' and
532                               (/bedework/appvar[key='monthViewMode']/value='cal' or
533                                not(/bedework/appvar[key='monthViewMode']))) or
534                               (/bedework/periodname='Week' and
535                               (/bedework/appvar[key='weekViewMode']/value='cal' or
536                                not(/bedework/appvar[key='weekViewMode'])))">
537                 <xsl:choose>
538                   <xsl:when test="/bedework/appvar[key='summaryMode']/value='details'">
539                     <img src="{$resourcesRoot}/images/std-button-summary-off.gif" width="62" height="21" border="0" alt="only summaries of events supported in this view"/>
540                   </xsl:when>
541                   <xsl:otherwise>
542                     <img src="{$resourcesRoot}/images/std-button-details-off.gif" width="62" height="21" border="0" alt="only summaries of events supported in this view"/>
543                   </xsl:otherwise>
544                 </xsl:choose>
545               </xsl:when>
546               <xsl:otherwise>
547                 <xsl:choose>
548                   <xsl:when test="/bedework/appvar[key='summaryMode']/value='details'">
549                     <a href="{$setup}&amp;setappvar=summaryMode(summary)" title="toggle summary/detailed view">
550                       <img src="{$resourcesRoot}/images/std-button-summary.gif" width="62" height="21" border="0" alt="toggle summary/detailed view"/>
551                     </a>
552                   </xsl:when>
553                   <xsl:otherwise>
554                     <a href="{$setup}&amp;setappvar=summaryMode(details)" title="toggle summary/detailed view">
555                       <img src="{$resourcesRoot}/images/std-button-details.gif" width="62" height="21" border="0" alt="toggle summary/detailed view"/>
556                     </a>
557                   </xsl:otherwise>
558                 </xsl:choose>
559               </xsl:otherwise>
560             </xsl:choose>
561             <a href="{$setup}"><img src="{$resourcesRoot}/images/std-button-refresh.gif" width="70" height="21" border="0" alt="refresh view"/></a>
562           </td>
563        </tr>
564     </table>
565   </xsl:template>
566
567   <!--==== SINGLE EVENT ====-->
568   <xsl:template match="event">
569     <xsl:variable name="subscriptionId" select="subscription/id"/>
570     <xsl:variable name="calPath" select="calendar/encodedPath"/>
571     <xsl:variable name="guid" select="guid"/>
572     <xsl:variable name="recurrenceId" select="recurrenceId"/>
573     <xsl:variable name="statusClass">
574       <xsl:choose>
575         <xsl:when test="status='CANCELLED'">bwStatusCancelled</xsl:when>
576         <xsl:when test="status='TENTATIVE'">bwStatusTentative</xsl:when>
577         <xsl:otherwise>bwStatusConfirmed</xsl:otherwise>
578       </xsl:choose>
579     </xsl:variable>
580     <h2 class="{$statusClass}">
581       <xsl:if test="status='CANCELLED'">CANCELLED: </xsl:if>
582       <xsl:choose>
583         <xsl:when test="link != ''">
584           <xsl:variable name="link" select="link"/>
585           <a href="{$link}">
586             <xsl:value-of select="summary"/>
587           </a>
588         </xsl:when>
589         <xsl:otherwise>
590           <xsl:value-of select="summary"/>
591         </xsl:otherwise>
592       </xsl:choose>
593     </h2>
594     <table id="eventTable" cellpadding="0" cellspacing="0">
595       <tr>
596         <td class="fieldname">When:</td>
597         <td class="fieldval">
598           <!-- always display local time -->
599           <xsl:value-of select="start/dayname"/>, <xsl:value-of select="start/longdate"/><xsl:text> </xsl:text>
600           <xsl:if test="start/allday = 'false'">
601             <span class="time"><xsl:value-of select="start/time"/></span>
602           </xsl:if>
603           <xsl:if test="(end/longdate != start/longdate) or
604                         ((end/longdate = start/longdate) and (end/time != start/time))"> - </xsl:if>
605           <xsl:if test="end/longdate != start/longdate">
606             <xsl:value-of select="substring(end/dayname,1,3)"/>, <xsl:value-of select="end/longdate"/><xsl:text> </xsl:text>
607           </xsl:if>
608           <xsl:choose>
609             <xsl:when test="start/allday = 'true'">
610               <span class="time"><em>(all day)</em></span>
611             </xsl:when>
612             <xsl:when test="end/longdate != start/longdate">
613               <span class="time"><xsl:value-of select="end/time"/></span>
614             </xsl:when>
615             <xsl:when test="end/time != start/time">
616               <span class="time"><xsl:value-of select="end/time"/></span>
617             </xsl:when>
618           </xsl:choose>
619           <!-- if timezones are not local, or if floating add labels: -->
620           <xsl:if test="start/timezone/islocal = 'false' or end/timezone/islocal = 'false'">
621             <xsl:text> </xsl:text>
622             --
623             <strong>
624               <xsl:choose>
625                 <xsl:when test="start/floating = 'true'">
626                   Floating time
627                 </xsl:when>
628                 <xsl:otherwise>
629                   Local time
630                 </xsl:otherwise>
631               </xsl:choose>
632             </strong>
633             <br/>
634           </xsl:if>
635           <!-- display in timezone if not local or floating time) -->
636           <xsl:if test="(start/timezone/islocal = 'false' or end/timezone/islocal = 'false') and start/floating = 'false'">
637             <xsl:choose>
638               <xsl:when test="start/timezone/id != end/timezone/id">
639                 <!-- need to display both timezones if they differ from start to end -->
640                 <table border="0" cellspacing="0" id="tztable">
641                   <tr>
642                     <td>
643                       <strong>Start:</strong>
644                     </td>
645                     <td>
646                       <xsl:choose>
647                         <xsl:when test="start/timezone/islocal='true'">
648                           <xsl:value-of select="start/dayname"/>,
649                           <xsl:value-of select="start/longdate"/>
650                           <xsl:text> </xsl:text>
651                           <span class="time"><xsl:value-of select="start/time"/></span>
652                         </xsl:when>
653                         <xsl:otherwise>
654                           <xsl:value-of select="start/timezone/dayname"/>,
655                           <xsl:value-of select="start/timezone/longdate"/>
656                           <xsl:text> </xsl:text>
657                           <span class="time"><xsl:value-of select="start/timezone/time"/></span>
658                         </xsl:otherwise>
659                       </xsl:choose>
660                     </td>
661                     <td>
662                       --
663                       <strong><xsl:value-of select="start/timezone/id"/></strong>
664                     </td>
665                   </tr>
666                   <tr>
667                     <td>
668                       <strong>End:</strong>
669                     </td>
670                     <td>
671                       <xsl:choose>
672                         <xsl:when test="end/timezone/islocal='true'">
673                           <xsl:value-of select="end/dayname"/>,
674                           <xsl:value-of select="end/longdate"/>
675                           <xsl:text> </xsl:text>
676                           <span class="time"><xsl:value-of select="end/time"/></span>
677                         </xsl:when>
678                         <xsl:otherwise>
679                           <xsl:value-of select="end/timezone/dayname"/>,
680                           <xsl:value-of select="end/timezone/longdate"/>
681                           <xsl:text> </xsl:text>
682                           <span class="time"><xsl:value-of select="end/timezone/time"/></span>
683                         </xsl:otherwise>
684                       </xsl:choose>
685                     </td>
686                     <td>
687                       --
688                       <strong><xsl:value-of select="end/timezone/id"/></strong>
689                     </td>
690                   </tr>
691                 </table>
692               </xsl:when>
693               <xsl:otherwise>
694                 <!-- otherwise, timezones are the same: display as a single line  -->
695                 <xsl:value-of select="start/timezone/dayname"/>, <xsl:value-of select="start/timezone/longdate"/><xsl:text> </xsl:text>
696                 <xsl:if test="start/allday = 'false'">
697                   <span class="time"><xsl:value-of select="start/timezone/time"/></span>
698                 </xsl:if>
699                 <xsl:if test="(end/timezone/longdate != start/timezone/longdate) or
700                               ((end/timezone/longdate = start/timezone/longdate) and (end/timezone/time != start/timezone/time))"> - </xsl:if>
701                 <xsl:if test="end/timezone/longdate != start/timezone/longdate">
702                   <xsl:value-of select="substring(end/timezone/dayname,1,3)"/>, <xsl:value-of select="end/timezone/longdate"/><xsl:text> </xsl:text>
703                 </xsl:if>
704                 <xsl:choose>
705                   <xsl:when test="start/allday = 'true'">
706                     <span class="time"><em>(all day)</em></span>
707                   </xsl:when>
708                   <xsl:when test="end/timezone/longdate != start/timezone/longdate">
709                     <span class="time"><xsl:value-of select="end/timezone/time"/></span>
710                   </xsl:when>
711                   <xsl:when test="end/timezone/time != start/timezone/time">
712                     <span class="time"><xsl:value-of select="end/timezone/time"/></span>
713                   </xsl:when>
714                 </xsl:choose>
715                 <xsl:text> </xsl:text>
716                 --
717                 <strong><xsl:value-of select="start/timezone/id"/></strong>
718               </xsl:otherwise>
719             </xsl:choose>
720           </xsl:if>
721         </td>
722         <th class="icalIcon" rowspan="2">
723           <div id="eventIcons">
724             <a href="{$privateCal}/event/addEventRef.do?subid={$subscriptionId}&amp;calPath={$calPath}&amp;guid={$guid}&amp;recurrenceId={$recurrenceId}" title="Add event to MyCalendar" target="myCalendar">
725               <img class="addref" src="{$resourcesRoot}/images/add2mycal-icon.gif" width="20" height="26" border="0" alt="Add event to MyCalendar"/>
726             add to my calendar</a>
727             <xsl:variable name="eventIcalName" select="concat($guid,'.ics')"/>
728             <a href="{$export}&amp;subid={$subscriptionId}&amp;calPath={$calPath}&amp;guid={$guid}&amp;recurrenceId={$recurrenceId}&amp;nocache=no&amp;skinName=ical&amp;contentType=text/calendar&amp;contentName={$eventIcalName}" title="Download event as ical - for Outlook, PDAs, iCal, and other desktop calendars">
729               <img src="{$resourcesRoot}/images/std-ical_icon.gif" width="20" height="26" border="0" alt="Download this event"/>
730              download</a>
731           </div>
732         </th>
733       </tr>
734       <tr>
735         <td class="fieldname">Where:</td>
736         <td class="fieldval">
737           <xsl:choose>
738             <xsl:when test="location/link=''">
739               <xsl:value-of select="location/address"/>
740             </xsl:when>
741             <xsl:otherwise>
742               <xsl:variable name="locationLink" select="location/link"/>
743               <a href="{$locationLink}">
744                 <xsl:value-of select="location/address"/>
745               </a>
746             </xsl:otherwise>
747           </xsl:choose>
748           <xsl:if test="location/subaddress!=''">
749             <br/><xsl:value-of select="location/subaddress"/>
750           </xsl:if>
751         </td>
752       </tr>
753       <tr>
754         <td class="fieldname">Description:</td>
755         <td colspan="2" class="fieldval description">
756           <xsl:call-template name="replace">
757             <xsl:with-param name="string" select="description"/>
758             <xsl:with-param name="pattern" select="'&#xA;'"/>
759             <xsl:with-param name="replacement"><br/></xsl:with-param>
760           </xsl:call-template>
761         </td>
762       </tr>
763       <xsl:if test="status !='' and status != 'CONFIRMED'">
764         <tr>
765           <td class="fieldname">Status:</td>
766           <td class="fieldval">
767             <xsl:value-of select="status"/>
768           </td>
769         </tr>
770       </xsl:if>
771       <xsl:if test="cost!=''">
772         <tr>
773           <td class="fieldname">Cost:</td>
774           <td colspan="2" class="fieldval"><xsl:value-of select="cost"/></td>
775         </tr>
776       </xsl:if>
777       <xsl:if test="link != ''">
778         <tr>
779           <td class="fieldname">See:</td>
780           <td colspan="2" class="fieldval">
781             <xsl:variable name="link" select="link"/>
782             <a href="{$link}"><xsl:value-of select="link"/></a>
783           </td>
784         </tr>
785       </xsl:if>
786       <xsl:if test="contact/name!='none'">
787         <tr>
788           <td class="fieldname">Contact:</td>
789           <td colspan="2" class="fieldval">
790             <xsl:choose>
791               <xsl:when test="contact/link=''">
792                 <xsl:value-of select="contact/name"/>
793               </xsl:when>
794               <xsl:otherwise>
795                 <xsl:variable name="sponsorLink" select="contact/link"/>
796                 <a href="{$sponsorLink}">
797                   <xsl:value-of select="contact/name"/>
798                 </a>
799               </xsl:otherwise>
800             </xsl:choose>
801             <xsl:if test="contact/phone!=''">
802               <br /><xsl:value-of select="contact/phone"/>
803             </xsl:if>
804             <!-- If you want to display email addresses, uncomment the
805                  following 8 lines. -->
806             <!-- <xsl:if test="contact/email!=''">
807               <br />
808               <xsl:variable name="email" select="contact/email"/>
809               <xsl:variable name="subject" select="summary"/>
810               <a href="mailto:{$email}&amp;subject={$subject}">
811                 <xsl:value-of select="contact/email"/>
812               </a>
813             </xsl:if> -->
814           </td>
815         </tr>
816       </xsl:if>
817       <xsl:if test="calendar/path!=''">
818         <tr>
819           <td class="fieldname">Calendar:</td>
820           <td class="fieldval">
821             <xsl:variable name="calUrl" select="calendar/encodedPath"/>
822             <a href="{$setSelection}&amp;calUrl={$calUrl}">
823               <xsl:value-of select="calendar/name"/>
824             </a>
825           </td>
826         </tr>
827       </xsl:if>
828       <xsl:if test="categories/category">
829         <tr>
830           <td class="fieldname">Categories:</td>
831           <td class="fieldval">
832             <xsl:for-each select="categories/category">
833               <xsl:value-of select="word"/><xsl:if test="position() != last()">, </xsl:if>
834             </xsl:for-each>
835           </td>
836         </tr>
837       </xsl:if>
838     </table>
839   </xsl:template>
840
841   <!--==== LIST VIEW  (for day, week, and month) ====-->
842   <xsl:template name="listView">
843     <table id="listTable" border="0" cellpadding="0" cellspacing="0">
844       <xsl:choose>
845         <xsl:when test="not(/bedework/eventscalendar/year/month/week/day/event)">
846           <tr>
847             <td class="noEventsCell">
848               No events to display.
849             </td>
850           </tr>
851         </xsl:when>
852         <xsl:otherwise>
853           <xsl:for-each select="/bedework/eventscalendar/year/month/week/day[event]">
854             <xsl:if test="/bedework/periodname='Week' or /bedework/periodname='Month' or /bedework/periodname=''">
855               <tr>
856                 <td colspan="5" class="dateRow">
857                    <xsl:variable name="date" select="date"/>
858                    <a href="{$setViewPeriod}&amp;viewType=dayView&amp;date={$date}">
859                      <xsl:value-of select="name"/>, <xsl:value-of select="longdate"/>
860                    </a>
861                 </td>
862               </tr>
863             </xsl:if>
864             <xsl:for-each select="event">
865               <xsl:variable name="id" select="id"/>
866               <xsl:variable name="subscriptionId" select="subscription/id"/>
867               <xsl:variable name="calPath" select="calendar/encodedPath"/>
868               <xsl:variable name="guid" select="guid"/>
869               <xsl:variable name="recurrenceId" select="recurrenceId"/>
870               <tr>
871                 <xsl:variable name="dateRangeStyle">
872                   <xsl:choose>
873                     <xsl:when test="start/shortdate = parent::day/shortdate">
874                       <xsl:choose>
875                         <xsl:when test="start/allday = 'true'">dateRangeCrossDay</xsl:when>
876                         <xsl:when test="start/hour24 &lt; 6">dateRangeEarlyMorning</xsl:when>
877                         <xsl:when test="start/hour24 &lt; 12">dateRangeMorning</xsl:when>
878                         <xsl:when test="start/hour24 &lt; 18">dateRangeAfternoon</xsl:when>
879                         <xsl:otherwise>dateRangeEvening</xsl:otherwise>
880                       </xsl:choose>
881                     </xsl:when>
882                     <xsl:otherwise>dateRangeCrossDay</xsl:otherwise>
883                   </xsl:choose>
884                 </xsl:variable>
885                 <xsl:choose>
886                   <xsl:when test="start/allday = 'true' and
887                                   start/shortdate = end/shortdate">
888                     <td class="{$dateRangeStyle} center" colspan="3">
889                       all day
890                     </td>
891                   </xsl:when>
892                   <xsl:when test="start/shortdate = end/shortdate and
893                                   start/time = end/time">
894                     <td class="{$dateRangeStyle} center" colspan="3">
895                       <a href="{$eventView}&amp;subid={$subscriptionId}&amp;calPath={$calPath}&amp;guid={$guid}&amp;recurrenceId={$recurrenceId}">
896                         <xsl:value-of select="start/time"/>
897                       </a>
898                     </td>
899                   </xsl:when>
900                   <xsl:otherwise>
901                     <td class="{$dateRangeStyle} right">
902                       <a href="{$eventView}&amp;subid={$subscriptionId}&amp;calPath={$calPath}&amp;guid={$guid}&amp;recurrenceId={$recurrenceId}">
903                       <xsl:choose>
904                         <xsl:when test="start/allday = 'true' and
905                                         parent::day/shortdate = start/shortdate">
906                           today
907                         </xsl:when>
908                         <xsl:when test="parent::day/shortdate != start/shortdate">
909                           <span class="littleArrow">&#171;</span>&#160;
910                           <xsl:value-of select="start/month"/>/<xsl:value-of select="start/day"/>
911                         </xsl:when>
912                         <xsl:otherwise>
913                           <xsl:value-of select="start/time"/>
914                         </xsl:otherwise>
915                       </xsl:choose>
916                       </a>
917                     </td>
918                     <td class="{$dateRangeStyle} center">
919                       <a href="{$eventView}&amp;subid={$subscriptionId}&amp;calPath={$calPath}&amp;guid={$guid}&amp;recurrenceId={$recurrenceId}">-</a>
920                     </td>
921                     <td class="{$dateRangeStyle} left">
922                       <a href="{$eventView}&amp;subid={$subscriptionId}&amp;calPath={$calPath}&amp;guid={$guid}&amp;recurrenceId={$recurrenceId}">
923                       <xsl:choose>
924                         <xsl:when test="end/allday = 'true' and
925                                         parent::day/shortdate = end/shortdate">
926                           today
927                         </xsl:when>
928                         <xsl:when test="parent::day/shortdate != end/shortdate">
929                           <xsl:value-of select="end/month"/>/<xsl:value-of select="end/day"/>
930                           &#160;<span class="littleArrow">&#187;</span>
931                         </xsl:when>
932                         <xsl:otherwise>
933                           <xsl:value-of select="end/time"/>
934                         </xsl:otherwise>
935                       </xsl:choose>
936                       </a>
937                     </td>
938                   </xsl:otherwise>
939                 </xsl:choose>
940                 <xsl:variable name="descriptionClass">
941                   <xsl:choose>
942                     <xsl:when test="status='CANCELLED'">description bwStatusCancelled</xsl:when>
943                     <xsl:when test="status='TENTATIVE'">description bwStatusTentative</xsl:when>
944                     <xsl:otherwise>description</xsl:otherwise>
945                   </xsl:choose>
946                 </xsl:variable>
947                 <td class="{$descriptionClass}">
948                   <xsl:if test="status='CANCELLED'"><strong>CANCELLED: </strong></xsl:if>
949                   <xsl:choose>
950                     <xsl:when test="/bedework/appvar[key='summaryMode']/value='details'">
951                       <a href="{$eventView}&amp;subid={$subscriptionId}&amp;calPath={$calPath}&amp;guid={$guid}&amp;recurrenceId={$recurrenceId}">
952                         <strong>
953                           <xsl:value-of select="summary"/>:
954                         </strong>
955                         <xsl:value-of select="description"/>&#160;
956                         <em>
957                           <xsl:value-of select="location/address"/>
958                           <xsl:if test="location/subaddress != ''">
959                             , <xsl:value-of select="location/subaddress"/>
960                           </xsl:if>.&#160;
961                           <xsl:if test="cost!=''">
962                             <xsl:value-of select="cost"/>.&#160;
963                           </xsl:if>
964                           <xsl:if test="contact/name!='none'">
965                             Contact: <xsl:value-of select="contact/name"/>
966                           </xsl:if>
967                         </em>
968                         - <xsl:value-of select="calendar/name"/>
969                       </a>
970                       <xsl:if test="link != ''">
971                         <xsl:variable name="link" select="link"/>
972                         <a href="{$link}" class="moreLink"><xsl:value-of select="link"/></a>
973                       </xsl:if>
974                     </xsl:when>
975                     <xsl:otherwise>
976                       <a href="{$eventView}&amp;subid={$subscriptionId}&amp;calPath={$calPath}&amp;guid={$guid}&amp;recurrenceId={$recurrenceId}">
977                         <xsl:value-of select="summary"/>
978                         <xsl:if test="location/address != ''">, <xsl:value-of select="location/address"/></xsl:if>
979                          - <em><xsl:value-of select="calendar/name"/></em>
980                       </a>
981                     </xsl:otherwise>
982                   </xsl:choose>
983                 </td>
984                 <td class="icons">
985                   <a href="{$privateCal}/event/addEventRef.do?subid={$subscriptionId}&amp;calPath={$calPath}&amp;guid={$guid}&amp;recurrenceId={$recurrenceId}" title="Add event to MyCalendar" target="myCalendar">
986                     <img class="addref" src="{$resourcesRoot}/images/add2mycal-icon-small.gif" width="12" height="16" border="0" alt="Add event to MyCalendar"/>
987                   </a>
988                   <xsl:variable name="eventIcalName" select="concat($id,'.ics')"/>
989                   <a href="{$export}&amp;subid={$subscriptionId}&amp;calPath={$calPath}&amp;guid={$guid}&amp;recurrenceId={$recurrenceId}&amp;nocache=no&amp;skinName=ical&amp;contentType=text/calendar&amp;contentName={$eventIcalName}" title="Download event as ical - for Outlook, PDAs, iCal, and other desktop calendars">
990                     <img src="{$resourcesRoot}/images/std-ical_icon_small.gif" width="12" height="16" border="0" alt="Download event as ical - for Outlook, PDAs, iCal, and other desktop calendars"/>
991                   </a>
992                 </td>
993               </tr>
994             </xsl:for-each>
995           </xsl:for-each>
996         </xsl:otherwise>
997       </xsl:choose>
998     </table>
999   </xsl:template>
1000
1001   <!--==== WEEK CALENDAR VIEW ====-->
1002   <xsl:template name="weekView">
1003     <table id="monthCalendarTable" border="0" cellpadding="0" cellspacing="0">
1004       <tr>
1005         <xsl:for-each select="/bedework/daynames/val">
1006           <th class="dayHeading"><xsl:value-of select="."/></th>
1007         </xsl:for-each>
1008       </tr>
1009       <tr>
1010         <xsl:for-each select="/bedework/eventscalendar/year/month/week/day">
1011           <xsl:variable name="dayPos" select="position()"/>
1012           <xsl:if test="filler='false'">
1013             <td>
1014               <xsl:if test="/bedework/now/date = date">
1015                 <xsl:attribute name="class">today</xsl:attribute>
1016               </xsl:if>
1017               <xsl:variable name="dayDate" select="date"/>
1018               <a href="{$setViewPeriod}&amp;viewType=dayView&amp;date={$dayDate}" class="dayLink">
1019                 <xsl:value-of select="value"/>
1020               </a>
1021               <xsl:if test="event">
1022                 <ul>
1023                   <xsl:apply-templates select="event" mode="calendarLayout">
1024                     <xsl:with-param name="dayPos" select="$dayPos"/>
1025                   </xsl:apply-templates>
1026                 </ul>
1027               </xsl:if>
1028             </td>
1029           </xsl:if>
1030         </xsl:for-each>
1031       </tr>
1032     </table>
1033   </xsl:template>
1034
1035   <!--==== MONTH CALENDAR VIEW ====-->
1036   <xsl:template name="monthView">
1037     <table id="monthCalendarTable" border="0" cellpadding="0" cellspacing="0">
1038       <tr>
1039         <xsl:for-each select="/bedework/daynames/val">
1040           <th class="dayHeading"><xsl:value-of select="."/></th>
1041         </xsl:for-each>
1042       </tr>
1043       <xsl:for-each select="/bedework/eventscalendar/year/month/week">
1044         <tr>
1045           <xsl:for-each select="day">
1046             <xsl:variable name="dayPos" select="position()"/>
1047             <xsl:choose>
1048               <xsl:when test="filler='true'">
1049                 <td class="filler">&#160;</td>
1050               </xsl:when>
1051               <xsl:otherwise>
1052                 <td>
1053                   <xsl:if test="/bedework/now/date = date">
1054                     <xsl:attribute name="class">today</xsl:attribute>
1055                   </xsl:if>
1056                   <xsl:variable name="dayDate" select="date"/>
1057                   <a href="{$setViewPeriod}&amp;viewType=dayView&amp;date={$dayDate}" class="dayLink">
1058                     <xsl:value-of select="value"/>
1059                   </a>
1060                   <xsl:if test="event">
1061                     <ul>
1062                       <xsl:apply-templates select="event" mode="calendarLayout">
1063                         <xsl:with-param name="dayPos" select="$dayPos"/>
1064                       </xsl:apply-templates>
1065                     </ul>
1066                   </xsl:if>
1067                 </td>
1068               </xsl:otherwise>
1069             </xsl:choose>
1070           </xsl:for-each>
1071         </tr>
1072       </xsl:for-each>
1073     </table>
1074   </xsl:template>
1075
1076   <!--== EVENTS IN THE CALENDAR GRID ==-->
1077   <xsl:template match="event" mode="calendarLayout">
1078     <xsl:param name="dayPos"/>
1079     <xsl:variable name="subscriptionId" select="subscription/id"/>
1080     <xsl:variable name="calPath" select="calendar/encodedPath"/>
1081     <xsl:variable name="guid" select="guid"/>
1082     <xsl:variable name="recurrenceId" select="recurrenceId"/>
1083     <xsl:variable name="eventClass">
1084       <xsl:choose>
1085         <!-- Special styles for the month grid -->
1086         <xsl:when test="status='CANCELLED'">eventCancelled</xsl:when>
1087         <xsl:when test="status='TENTATIVE'">eventTentative</xsl:when>
1088         <!-- Default alternating colors for all standard events -->
1089         <xsl:when test="position() mod 2 = 1">eventLinkA</xsl:when>
1090         <xsl:otherwise>eventLinkB</xsl:otherwise>
1091       </xsl:choose>
1092     </xsl:variable>
1093     <!-- Subscription styles.
1094          These are set in the add/modify subscription forms in the admin client;
1095          if present, these override the background-color set by eventClass. The
1096          subscription styles should not be used for cancelled events (tentative is ok). -->
1097     <xsl:variable name="subscriptionClass">
1098       <xsl:if test="status != 'CANCELLED' and
1099                     subscription/subStyle != '' and
1100                     subscription/subStyle != 'default'"><xsl:value-of select="subscription/subStyle"/></xsl:if>
1101     </xsl:variable>
1102     <li>
1103       <a href="{$eventView}&amp;subid={$subscriptionId}&amp;calPath={$calPath}&amp;guid={$guid}&amp;recurrenceId={$recurrenceId}" class="{$eventClass} {$subscriptionClass}">
1104         <xsl:if test="status='CANCELLED'">CANCELLED: </xsl:if>
1105         <xsl:choose>
1106           <xsl:when test="start/shortdate != ../shortdate">
1107             (cont)
1108           </xsl:when>
1109           <xsl:when test="start/allday = 'false'">
1110             <xsl:value-of select="start/time"/>:
1111           </xsl:when>
1112           <xsl:otherwise>
1113             all day:
1114           </xsl:otherwise>
1115         </xsl:choose>
1116         <xsl:value-of select="summary"/>
1117         <xsl:variable name="eventTipClass">
1118           <xsl:choose>
1119             <xsl:when test="$dayPos &gt; 5">eventTipReverse</xsl:when>
1120             <xsl:otherwise>eventTip</xsl:otherwise>
1121           </xsl:choose>
1122         </xsl:variable>
1123         <span class="{$eventTipClass}">
1124           <xsl:if test="status='CANCELLED'"><span class="eventTipStatusCancelled">CANCELLED</span></xsl:if>
1125           <xsl:if test="status='TENTATIVE'"><span class="eventTipStatusTentative">TENTATIVE</span></xsl:if>
1126           <strong><xsl:value-of select="summary"/></strong><br/>
1127           Time:
1128           <xsl:choose>
1129             <xsl:when test="start/allday = 'true'">
1130               all day
1131             </xsl:when>
1132             <xsl:otherwise>
1133               <xsl:if test="start/shortdate != ../shortdate">
1134                 <xsl:value-of select="start/month"/>/<xsl:value-of select="start/day"/>
1135                 <xsl:text> </xsl:text>
1136               </xsl:if>
1137               <xsl:value-of select="start/time"/>
1138               <xsl:if test="(start/time != end/time) or (start/shortdate != end/shortdate)">
1139                 -
1140                 <xsl:if test="end/shortdate != ../shortdate">
1141                   <xsl:value-of select="end/month"/>/<xsl:value-of select="end/day"/>
1142                   <xsl:text> </xsl:text>
1143                 </xsl:if>
1144                 <xsl:value-of select="end/time"/>
1145               </xsl:if>
1146             </xsl:otherwise>
1147           </xsl:choose><br/>
1148           <xsl:if test="location/address">
1149             Location: <xsl:value-of select="location/address"/><br/>
1150           </xsl:if>
1151           Calendar: <xsl:value-of select="calendar/name"/>
1152         </span>
1153       </a>
1154     </li>
1155   </xsl:template>
1156
1157   <!--==== YEAR VIEW ====-->
1158   <xsl:template name="yearView">
1159     <table id="yearCalendarTable" border="0" cellpadding="0" cellspacing="0">
1160       <tr>
1161         <xsl:apply-templates select="/bedework/eventscalendar/year/month[position() &lt;= 3]"/>
1162       </tr>
1163       <tr>
1164         <xsl:apply-templates select="/bedework/eventscalendar/year/month[(position() &gt; 3) and (position() &lt;= 6)]"/>
1165       </tr>
1166       <tr>
1167         <xsl:apply-templates select="/bedework/eventscalendar/year/month[(position() &gt; 6) and (position() &lt;= 9)]"/>
1168       </tr>
1169       <tr>
1170         <xsl:apply-templates select="/bedework/eventscalendar/year/month[position() &gt; 9]"/>
1171       </tr>
1172     </table>
1173   </xsl:template>
1174
1175   <!-- year view month tables -->
1176   <xsl:template match="month">
1177     <td>
1178       <table class="yearViewMonthTable" border="0" cellpadding="0" cellspacing="0">
1179         <tr>
1180           <td colspan="8" class="monthName">
1181             <xsl:variable name="firstDayOfMonth" select="week/day/date"/>
1182             <a href="{$setViewPeriod}&amp;viewType=monthView&amp;date={$firstDayOfMonth}">
1183               <xsl:value-of select="longname"/>
1184             </a>
1185           </td>
1186         </tr>
1187         <tr>
1188           <th>&#160;</th>
1189           <xsl:for-each select="/bedework/shortdaynames/val">
1190             <th><xsl:value-of select="."/></th>
1191           </xsl:for-each>
1192         </tr>
1193         <xsl:for-each select="week">
1194           <tr>
1195             <td class="weekCell">
1196               <xsl:variable name="firstDayOfWeek" select="day/date"/>
1197               <a href="{$setViewPeriod}&amp;viewType=weekView&amp;date={$firstDayOfWeek}">
1198                 <xsl:value-of select="value"/>
1199               </a>
1200             </td>
1201             <xsl:for-each select="day">
1202               <xsl:choose>
1203                 <xsl:when test="filler='true'">
1204                   <td class="filler">&#160;</td>
1205                 </xsl:when>
1206                 <xsl:otherwise>
1207                   <td>
1208                     <xsl:if test="/bedework/now/date = date">
1209                       <xsl:attribute name="class">today</xsl:attribute>
1210                     </xsl:if>
1211                     <xsl:variable name="dayDate" select="date"/>
1212                     <a href="{$setViewPeriod}&amp;viewType=dayView&amp;date={$dayDate}">
1213                       <xsl:attribute name="class">today</xsl:attribute>
1214                       <xsl:value-of select="value"/>
1215                     </a>
1216                   </td>
1217                 </xsl:otherwise>
1218               </xsl:choose>
1219             </xsl:for-each>
1220           </tr>
1221         </xsl:for-each>
1222       </table>
1223     </td>
1224   </xsl:template>
1225
1226   <!--==== CALENDARS PAGE ====-->
1227   <xsl:template match="calendars">
1228     <xsl:variable name="topLevelCalCount" select="count(calendar/calendar)"/>
1229     <table id="calPageTable" border="0" cellpadding="0" cellspacing="0">
1230       <tr>
1231         <th colspan="2">
1232           All Calendars
1233         </th>
1234       </tr>
1235       <tr>
1236         <td colspan="2" class="infoCell">
1237           <p class="info">
1238             Select a calendar from the list below to see only that calendar's events.
1239           </p>
1240           <div dojoType="FloatingPane" id="bwCalendarExportWidget"
1241                title="Export Calendar as iCal" toggle="plain"
1242                windowState="minimized" hasShadow="true"
1243                displayMinimizeAction="true" resizable="false">
1244              <p>
1245               <strong>Calendar to export:</strong>
1246               <span id="bwCalendarExportWidgetCalName"></span>
1247             </p>
1248             <strong>Event date limits:</strong>
1249             <form name="exportCalendarForm" id="exportCalendarForm" action="{$export}" method="post">
1250               <!-- this value is passed into the form when the widget is requested -->
1251               <input type="hidden" name="calPath" value=""/>
1252               <!-- fill these on submit -->
1253               <input type="hidden" name="eventStartDate.year" value=""/>
1254               <input type="hidden" name="eventStartDate.month" value=""/>
1255               <input type="hidden" name="eventStartDate.day" value=""/>
1256               <input type="hidden" name="eventEndDate.year" value=""/>
1257               <input type="hidden" name="eventEndDate.month" value=""/>
1258               <input type="hidden" name="eventEndDate.day" value=""/>
1259               <!-- static fields -->
1260               <input type="hidden" name="nocache" value="no"/>
1261               <input type="hidden" name="skinName" value="ical"/>
1262               <input type="hidden" name="contentType" value="text/calendar"/>
1263               <input type="hidden" name="contentName" value="calendar.ics"/>
1264               <!-- visible fields -->
1265               <input type="radio" name="dateLimits" value="active" checked="checked" onclick="changeClass('exportDateRange','invisible')"/> today forward
1266               <input type="radio" name="dateLimits" value="none" onclick="changeClass('exportDateRange','invisible')"/> all dates
1267               <input type="radio" name="dateLimits" value="limited" onclick="changeClass('exportDateRange','visible')"/> date range
1268               <div id="exportDateRange" class="invisible">
1269                 Start: <div dojoType="dropdowndatepicker" formatLength="medium" saveFormat="yyyyMMdd" id="bwExportCalendarWidgetStartDate"><xsl:text> </xsl:text></div>
1270                 End: <div dojoType="dropdowndatepicker" formatLength="medium" saveFormat="yyyyMMdd" id="bwExportCalendarWidgetEndDate"><xsl:text> </xsl:text></div>
1271               </div>
1272               <p><input type="submit" value="export" class="bwWidgetSubmit" onclick="fillExportFields('exportCalendarForm');hideWidget('bwCalendarExportWidget')"/></p>
1273             </form>
1274           </div>
1275         </td>
1276       </tr>
1277       <tr>
1278         <td class="leftCell">
1279           <ul class="calendarTree">
1280             <xsl:apply-templates select="calendar/calendar[position() &lt;= ceiling($topLevelCalCount div 2)]" mode="calTree"/>
1281           </ul>
1282         </td>
1283         <td>
1284           <ul class="calendarTree">
1285             <xsl:apply-templates select="calendar/calendar[position() &gt; ceiling($topLevelCalCount div 2)]" mode="calTree"/>
1286           </ul>
1287         </td>
1288       </tr>
1289     </table>
1290   </xsl:template>
1291
1292   <xsl:template match="calendar" mode="calTree">
1293     <xsl:variable name="itemClass">
1294       <xsl:choose>
1295         <xsl:when test="calendarCollection='false'">folder</xsl:when>
1296         <xsl:otherwise>calendar</xsl:otherwise>
1297       </xsl:choose>
1298     </xsl:variable>
1299     <xsl:variable name="url" select="encodedPath"/>
1300     <li class="{$itemClass}">
1301       <a href="{$setSelection}&amp;calUrl={$url}" title="view calendar"><xsl:value-of select="name"/></a>
1302       <xsl:if test="calendarCollection='true'">
1303         <xsl:variable name="name" select="name"/>
1304         <xsl:variable name="calPath" select="path"/>
1305         <xsl:variable name="idForCal" select="translate(translate(path,'/','S'),' ','s')"/>
1306         <span class="exportCalLink">
1307           <a href="javascript:launchExportWidget('exportCalendarForm','{$export}','{$name}','{$calPath}')" id="{$idForCal}" title="export calendar as iCal">
1308             <img src="{$resourcesRoot}/images/calIconExport-sm.gif" width="13" height="13" alt="export calendar" border="0"/>
1309           </a>
1310         </span>
1311       </xsl:if>
1312       <xsl:if test="calendar">
1313         <ul>
1314           <xsl:apply-templates select="calendar" mode="calTree"/>
1315         </ul>
1316       </xsl:if>
1317     </li>
1318   </xsl:template>
1319
1320   <!--==== SEARCH RESULT ====-->
1321   <xsl:template name="searchResult">
1322     <h2 class="bwStatusConfirmed">
1323       <div id="searchFilter">
1324         <form name="searchForm" method="post" action="{$search}">
1325           Search:
1326           <input type="text" name="query" size="15">
1327             <xsl:attribute name="value"><xsl:value-of select="/bedework/searchResults/query"/></xsl:attribute>
1328           </input>
1329           <input type="submit" name="submit" value="go"/>
1330           Limit:
1331           <xsl:choose>
1332             <xsl:when test="/bedework/searchResults/searchLimits = 'beforeToday'">
1333               <input type="radio" name="searchLimits" value="fromToday"/>today forward
1334               <input type="radio" name="searchLimits" value="beforeToday" checked="checked"/>past dates
1335               <input type="radio" name="searchLimits" value="none"/>all dates
1336             </xsl:when>
1337             <xsl:when test="/bedework/searchResults/searchLimits = 'none'">
1338               <input type="radio" name="searchLimits" value="fromToday"/>today forward
1339               <input type="radio" name="searchLimits" value="beforeToday"/>past dates
1340               <input type="radio" name="searchLimits" value="none" checked="checked"/>all dates
1341             </xsl:when>
1342             <xsl:otherwise>
1343               <input type="radio" name="searchLimits" value="fromToday" checked="checked"/>today forward
1344               <input type="radio" name="searchLimits" value="beforeToday"/>past dates
1345               <input type="radio" name="searchLimits" value="none"/>all dates
1346             </xsl:otherwise>
1347           </xsl:choose>
1348         </form>
1349       </div>
1350       Search Result
1351     </h2>
1352     <table id="searchTable" cellpadding="0" cellspacing="0">
1353       <tr>
1354         <th colspan="5">
1355           <xsl:if test="/bedework/searchResults/numPages &gt; 1">
1356             <xsl:variable name="curPage" select="/bedework/searchResults/curPage"/>
1357             <div id="searchPageForm">
1358               page:
1359               <xsl:if test="/bedework/searchResults/curPage != 1">
1360                 <xsl:variable name="prevPage" select="number($curPage) - 1"/>
1361                 &lt;<a href="{$search-next}&amp;pageNum={$prevPage}">prev</a>
1362               </xsl:if>
1363               <xsl:text> </xsl:text>
1364
1365               <xsl:call-template name="searchResultPageNav">
1366                 <xsl:with-param name="page">
1367                   <xsl:choose>
1368                     <xsl:when test="number($curPage) - 10 &lt; 1">1</xsl:when>
1369                     <xsl:otherwise><xsl:value-of select="number($curPage) - 6"/></xsl:otherwise>
1370                   </xsl:choose>
1371                 </xsl:with-param>
1372               </xsl:call-template>
1373
1374               <xsl:text> </xsl:text>
1375               <xsl:choose>
1376                 <xsl:when test="$curPage != /bedework/searchResults/numPages">
1377                   <xsl:variable name="nextPage" select="number($curPage) + 1"/>
1378                   <a href="{$search-next}&amp;pageNum={$nextPage}">next</a>&gt;
1379                 </xsl:when>
1380                 <xsl:otherwise>
1381                   <span class="hidden">next&gt;</span><!-- occupy the space to keep the navigation from moving around -->
1382                 </xsl:otherwise>
1383               </xsl:choose>
1384             </div>
1385           </xsl:if>
1386           <xsl:value-of select="/bedework/searchResults/resultSize"/>
1387           result<xsl:if test="/bedework/searchResults/resultSize != 1">s</xsl:if> returned
1388           for <em><xsl:value-of select="/bedework/searchResults/query"/></em>
1389         </th>
1390       </tr>
1391       <xsl:if test="/bedework/searchResults/searchResult">
1392         <tr class="fieldNames">
1393           <td>
1394             relevance
1395           </td>
1396           <td>
1397             summary
1398           </td>
1399           <td>
1400             date &amp; time
1401           </td>
1402           <td>
1403             calendar
1404           </td>
1405           <td>
1406             location
1407           </td>
1408         </tr>
1409       </xsl:if>
1410       <xsl:for-each select="/bedework/searchResults/searchResult">
1411         <xsl:variable name="subscriptionId" select="event/subscription/id"/>
1412         <xsl:variable name="calPath" select="event/calendar/encodedPath"/>
1413         <xsl:variable name="guid" select="event/guid"/>
1414         <xsl:variable name="recurrenceId" select="event/recurrenceId"/>
1415         <tr>
1416           <td class="relevance">
1417             <xsl:value-of select="ceiling(number(score)*100)"/>%
1418             <img src="{$resourcesRoot}/images/spacer.gif" height="4" class="searchRelevance">
1419               <xsl:attribute name="width"><xsl:value-of select="ceiling((number(score)*100) div 1.5)"/></xsl:attribute>
1420             </img>
1421           </td>
1422           <td>
1423             <a href="{$eventView}&amp;subid={$subscriptionId}&amp;calPath={$calPath}&amp;guid={$guid}&amp;recurrenceId={$recurrenceId}">
1424               <xsl:value-of select="event/summary"/>
1425             </a>
1426           </td>
1427           <td>
1428             <xsl:value-of select="event/start/longdate"/>
1429             <xsl:text> </xsl:text>
1430             <xsl:value-of select="event/start/time"/>
1431             <xsl:choose>
1432               <xsl:when test="event/start/longdate != event/end/longdate">
1433                 - <xsl:value-of select="event/start/longdate"/>
1434                 <xsl:text> </xsl:text>
1435                 <xsl:value-of select="event/end/time"/>
1436               </xsl:when>
1437               <xsl:when test="event/start/time != event/end/time">
1438                 - <xsl:value-of select="event/end/time"/>
1439               </xsl:when>
1440             </xsl:choose>
1441           </td>
1442           <td>
1443             <xsl:variable name="calUrl" select="event/calendar/encodedPath"/>
1444             <a href="{$setSelection}&amp;calUrl={$calUrl}">
1445               <xsl:value-of select="event/calendar/name"/>
1446             </a>
1447           </td>
1448           <td>
1449             <xsl:value-of select="event/location/address"/>
1450           </td>
1451         </tr>
1452       </xsl:for-each>
1453     </table>
1454   </xsl:template>
1455
1456   <xsl:template name="searchResultPageNav">
1457     <xsl:param name="page">1</xsl:param>
1458     <xsl:variable name="curPage" select="/bedework/searchResults/curPage"/>
1459     <xsl:variable name="numPages" select="/bedework/searchResults/numPages"/>
1460     <xsl:variable name="endPage">
1461       <xsl:choose>
1462         <xsl:when test="number($curPage) + 6 &gt; number($numPages)"><xsl:value-of select="$numPages"/></xsl:when>
1463         <xsl:otherwise><xsl:value-of select="number($curPage) + 6"/></xsl:otherwise>
1464       </xsl:choose>
1465     </xsl:variable>
1466     <xsl:choose>
1467       <xsl:when test="$page = $curPage">
1468         <xsl:value-of select="$page"/>
1469       </xsl:when>
1470       <xsl:otherwise>
1471         <a href="{$search-next}&amp;pageNum={$page}">
1472           <xsl:value-of select="$page"/>
1473         </a>
1474       </xsl:otherwise>
1475     </xsl:choose>
1476     <xsl:text> </xsl:text>
1477     <xsl:if test="$page &lt; $endPage">
1478        <xsl:call-template name="searchResultPageNav">
1479          <xsl:with-param name="page" select="number($page)+1"/>
1480       </xsl:call-template>
1481     </xsl:if>
1482   </xsl:template>
1483
1484   <!--+++++++++++++++ System Stats ++++++++++++++++++++-->
1485   <xsl:template name="stats">
1486     <div id="stats">
1487       <h2>System Statistics</h2>
1488
1489       <p>
1490         Stats collection:
1491       </p>
1492       <ul>
1493         <li>
1494           <a href="{$stats}&amp;enable=yes">enable</a> |
1495           <a href="{$stats}&amp;disable=yes">disable</a>
1496         </li>
1497         <li><a href="{$stats}&amp;fetch=yes">fetch statistics</a></li>
1498         <li><a href="{$stats}&amp;dump=yes">dump stats to log</a></li>
1499       </ul>
1500       <table id="statsTable" cellpadding="0">
1501         <xsl:for-each select="/bedework/sysStats/*">
1502           <xsl:choose>
1503             <xsl:when test="name(.) = 'header'">
1504               <tr>
1505                 <th colspan="2">
1506                   <xsl:value-of select="."/>
1507                 </th>
1508               </tr>
1509             </xsl:when>
1510             <xsl:otherwise>
1511               <tr>
1512                 <td class="label">
1513                   <xsl:value-of select="label"/>
1514                 </td>
1515                 <td class="value">
1516                   <xsl:value-of select="value"/>
1517                 </td>
1518               </tr>
1519             </xsl:otherwise>
1520           </xsl:choose>
1521         </xsl:for-each>
1522       </table>
1523     </div>
1524   </xsl:template>
1525
1526   <!--==== UTILITY TEMPLATES ====-->
1527
1528   <!-- search and replace template taken from
1529        http://www.biglist.com/lists/xsl-list/archives/200211/msg00337.html -->
1530   <xsl:template name="replace">
1531     <xsl:param name="string" select="''"/>
1532     <xsl:param name="pattern" select="''"/>
1533     <xsl:param name="replacement" select="''"/>
1534     <xsl:choose>
1535       <xsl:when test="$pattern != '' and $string != '' and contains($string, $pattern)">
1536         <xsl:value-of select="substring-before($string, $pattern)"/>
1537         <xsl:copy-of select="$replacement"/>
1538         <xsl:call-template name="replace">
1539           <xsl:with-param name="string" select="substring-after($string, $pattern)"/>
1540           <xsl:with-param name="pattern" select="$pattern"/>
1541           <xsl:with-param name="replacement" select="$replacement"/>
1542         </xsl:call-template>
1543       </xsl:when>
1544       <xsl:otherwise>
1545         <xsl:value-of select="$string"/>
1546       </xsl:otherwise>
1547     </xsl:choose>
1548   </xsl:template>
1549
1550   <!--==== FOOTER ====-->
1551
1552   <xsl:template name="footer">
1553     <div id="footer">
1554       Demonstration calendar; place footer information here.
1555     </div>
1556     <div id="subFoot">
1557       Based on the <a href="http://www.bedework.org/">Bedework Calendar</a> |
1558       <a href="?noxslt=yes">show XML</a> |
1559       <a href="?refreshXslt=yes">refresh XSLT</a>
1560     </div>
1561   </xsl:template>
1562 </xsl:stylesheet>
Note: See TracBrowser for help on using the browser.