Large reorganization of the web site
[www/www.git] / cscweb.xsl
1 <?xml version='1.0'?>
2
3 <xsl:stylesheet version="2.0"
4     xmlns="http://www.w3.org/1999/xhtml"
5     xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
6     xmlns:xs="http://www.w3.org/2001/XMLSchema"
7     xmlns:fn="http://www.w3.org/2005/xpath-functions"
8     xmlns:csc="http://csclub.uwaterloo.ca/xslt">
9
10 <xsl:param name="g_date" required="yes" />
11 <xsl:param name="g_time" required="yes" />
12 <xsl:param name="g_pwd" required="yes" />
13 <xsl:param name="g_root" required="yes" />
14
15 <!--
16
17   Set global "pre" variable based on /cscpage/@pre, which represents the 
18   relative path needed to get to the root. If you do not include a "pre" 
19   attribute on cscpage then the "pre" attribute will default to "../".
20
21 -->
22 <xsl:variable name="pre">
23  <xsl:choose>
24   <xsl:when test="/cscpage/@pre"><xsl:value-of select="/cscpage/@pre" /></xsl:when>
25   <xsl:otherwise>../</xsl:otherwise>
26  </xsl:choose>
27 </xsl:variable>
28
29 <!-- mirror variables -->
30 <xsl:variable name="mirror_csc">http://csclub.uwaterloo.ca/files/</xsl:variable>
31 <xsl:variable name="mirror_cs">http://mirror.cs.uwaterloo.ca/csclub/</xsl:variable>
32
33 <xsl:output method="xml" encoding="ISO-8859-1" doctype-public="-//W3C//DTD XHTML 1.0 Strict//EN" doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd" />
34
35 <!-- include additional style sheets -->
36 <xsl:include href="./xsl/functions.xsl" />
37 <xsl:include href="./xsl/common.xsl" />
38 <xsl:include href="./xsl/directory.xsl" />
39 <xsl:include href="./xsl/exec.xsl" />
40 <xsl:include href="./xsl/members.xsl" />
41 <xsl:include href="./xsl/events.xsl" />
42 <xsl:include href="./xsl/news.xsl" />
43 <xsl:include href="./xsl/media.xsl" />
44
45 <xsl:template match="*">
46   <xsl:copy>
47     <xsl:copy-of select="@*" />
48     <xsl:apply-templates />
49   </xsl:copy>
50 </xsl:template>
51
52 </xsl:stylesheet>