ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/repos/FeepingCreaturism/jargon.xsl
Revision: 229
Committed: 2004-09-06T16:50:13-07:00 (20 years, 9 months ago) by Douglas Thrift
Content type: text/xml
File size: 5986 byte(s)
Log Message:
Stuff.

File Contents

# Content
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3 Feeping Creaturism
4
5 Douglas Thrift
6
7 $Id$
8 -->
9 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
10 xmlns:xhtml="http://www.w3.org/1999/xhtml" exclude-result-prefixes="xhtml">
11 <xsl:output encoding="UTF-8" omit-xml-declaration="yes"
12 doctype-public="-//W3C//DTD XHTML 1.0 Strict//EN"
13 doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"/>
14 <xsl:param name="include"/>
15 <xsl:param name="relative">..</xsl:param>
16 <xsl:variable name="letter"
17 select="/xhtml:html/xhtml:head/xhtml:link[@rel='up']/@title"/>
18 <xsl:template match="xhtml:html">
19 <xsl:choose>
20 <xsl:when test="boolean($include)">
21 <xsl:apply-templates select="xhtml:body"/>
22 </xsl:when>
23 <xsl:otherwise>
24 <xsl:call-template name="page"/>
25 </xsl:otherwise>
26 </xsl:choose>
27 </xsl:template>
28 <xsl:template name="page">
29 <html xmlns="http://www.w3.org/1999/xhtml">
30 <head>
31 <title>Douglas Thrift's Computers Website | Jargon:
32 <xsl:value-of select="xhtml:head/xhtml:title"/></title>
33 <link rel="stylesheet" href="../../stylesheets/regular.css"
34 type="text/css"/>
35 <link rel="Icon" href="../../favicon.ico" type="image/ico"/>
36 <script src="../../nav/functions.js" type="text/javascript"
37 ></script>
38 </head>
39 <body>
40 <div>
41 <p class="center"><a
42 href="http://computers.douglasthrift.net/"><img
43 src="../../masthead.png"
44 alt="Douglas Thrift's Computers Website"
45 title="Douglas Thrift's Computers Website"
46 /></a></p>
47 <p class="center nav"><a
48 href="http://www.douglasthrift.net/"
49 onmouseout="deselect(1)" onmouseover="select(1)"
50 class="nav">Home</a> | <a
51 href="http://www.douglasthrift.net/blog/"
52 onmouseout="deselect(2)" onmouseover="select(2)"
53 class="nav">Blog</a> | <a
54 href="http://computers.douglasthrift.net/"
55 class="nav select">Computers</a> | <a
56 href="http://movies.douglasthrift.net/"
57 onmouseout="deselect(4)" onmouseover="select(4)"
58 class="nav">Movies</a> | <a
59 href="http://music.douglasthrift.net/"
60 onmouseout="deselect(5)" onmouseover="select(5)"
61 class="nav">Music</a> | <a
62 href="http://tvshows.douglasthrift.net/"
63 onmouseout="deselect(6)" onmouseover="select(6)"
64 class="nav">TV Shows</a> | <a
65 href="http://www.douglasthrift.net/sitemap.xml"
66 onmouseout="deselect(7)" onmouseover="select(7)"
67 class="nav">Sitemap</a> | <a
68 href="http://www.douglasthrift.net/contact.php"
69 onmouseout="deselect(8)" onmouseover="select(8)"
70 class="nav">Contact</a> | <a
71 href="http://www.douglasthrift.net/linking.xml"
72 onmouseout="deselect(9)" onmouseover="select(9)"
73 class="nav">Linking</a> | <a
74 href="http://www.douglasthrift.net/search.cgi"
75 onmouseout="deselect(10)" onmouseover="select(10)"
76 class="nav">Search</a></p>
77 </div>
78 <div class="hr">
79 <h1 id="title" class="center">Jargon: <xsl:value-of
80 select="xhtml:head/xhtml:title"/></h1>
81 </div>
82 <div class="hr">
83 <xsl:apply-templates select="xhtml:body"/>
84 </div>
85 <div class="hr">
86 <p class="center">Copyright &#xa9; 2002-2004, <a
87 href="http://www.douglasthrift.net/contact.php"
88 >Douglas Thrift</a>. All Rights Reserved.</p>
89 <p class="center"><a
90 href="http://validator.w3.org/check/referer"><img
91 src="../../w3c_images/vxh10.png"
92 alt="Valid XHTML 1.0!" title="Valid XHTML 1.0!"
93 /></a> <a
94 href="http://jigsaw.w3.org/css-validator/check/referer"
95 ><img src="../../w3c_images/vcss.png"
96 alt="Valid CSS!" title="Valid CSS!"/></a></p>
97 </div>
98 </body>
99 </html>
100 </xsl:template>
101 <xsl:template match="xhtml:body">
102 <p xmlns="http://www.w3.org/1999/xhtml"><strong><xsl:value-of
103 select="../xhtml:head/xhtml:title"/>: </strong>
104 <xsl:apply-templates select="xhtml:dt/dt"/></p>
105 <xsl:apply-templates select="xhtml:dd/*"/>
106 </xsl:template>
107 <xsl:template match="xhtml:dt/dt">
108 <xsl:for-each select="xhtml:span">
109 <xsl:value-of select="."/>
110 <xsl:if test="position()&lt;count(../xhtml:span)">, </xsl:if>
111 </xsl:for-each>
112 </xsl:template>
113 <xsl:template match="xhtml:p"><p xmlns="http://www.w3.org/1999/xhtml"
114 ><xsl:apply-templates/></p></xsl:template>
115 <xsl:template match="xhtml:i">
116 <i xmlns="http://www.w3.org/1999/xhtml"><xsl:apply-templates/></i>
117 </xsl:template>
118 <xsl:template match="xhtml:a">
119 <xsl:choose>
120 <xsl:when test="$relative!='..' and starts-with(@href,'..')"><a
121 xmlns="http://www.w3.org/1999/xhtml"
122 href="{$relative}{substring(@href,3)}"
123 ><xsl:apply-templates/></a>
124 </xsl:when>
125 <xsl:when
126 test="not(starts-with(@href,'..') or contains(@href,'http://'))"
127 ><a xmlns="http://www.w3.org/1999/xhtml"
128 href="{$relative}/{$letter}/{@href}"><xsl:apply-templates
129 /></a>
130 </xsl:when>
131 <xsl:otherwise><a xmlns="http://www.w3.org/1999/xhtml"
132 href="{@href}"><xsl:apply-templates/></a>
133 </xsl:otherwise>
134 </xsl:choose>
135 </xsl:template>
136 <xsl:template match="xhtml:tt">
137 <tt xmlns="http://www.w3.org/1999/xhtml"><xsl:apply-templates/></tt>
138 </xsl:template>
139 <xsl:template match="xhtml:em">
140 <em xmlns="http://www.w3.org/1999/xhtml"><xsl:apply-templates/></em>
141 </xsl:template>
142 <xsl:template match="xhtml:tr">
143 <tr xmlns="http://www.w3.org/1999/xhtml"><xsl:apply-templates/></tr>
144 </xsl:template>
145 <xsl:template match="xhtml:td">
146 <td xmlns="http://www.w3.org/1999/xhtml"><xsl:apply-templates/></td>
147 </xsl:template>
148 <xsl:template match="xhtml:span">
149 <span xmlns="http://www.w3.org/1999/xhtml"><xsl:apply-templates/></span>
150 </xsl:template>
151 <xsl:template match="xhtml:table">
152 <table xmlns="http://www.w3.org/1999/xhtml"><xsl:apply-templates/>
153 </table>
154 </xsl:template>
155 <xsl:template match="xhtml:tbody">
156 <tbody xmlns="http://www.w3.org/1999/xhtml"><xsl:apply-templates/>
157 </tbody>
158 </xsl:template>
159 </xsl:stylesheet>

Properties

Name Value
svn:eol-style native
svn:keywords Id