add test for searchCache and searchWordListCache
[mdictionary] / trunk / src / base / xsl.xsl
1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <xsl:stylesheet version="2.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
3
4 <xsl:template match="/">
5         <html>
6         <body>
7         <table border="1" WIDTH="100%">
8         <tr bgcolor="#99CCFF">
9                 <th><xsl:value-of select="ar/dict[1]/key"/></th>
10         </tr>
11         <xsl:for-each select="ar/dict"> 
12                 <tr bgcolor="#99FF99">
13                         <th><xsl:value-of select="info"/></th>
14                 </tr>
15                 <xsl:for-each select="t">
16                         <tr>
17                         <td><xsl:apply-templates/></td>
18                         </tr>
19                 </xsl:for-each> 
20         </xsl:for-each>
21         </table>
22         </body>
23         </html>
24 </xsl:template> 
25
26 <xsl:template match="tr">
27         [<i><xsl:apply-templates/></i>]
28 </xsl:template> 
29
30 <xsl:template match="pot">
31         ,<i><xsl:apply-templates/></i>
32 </xsl:template>
33
34 <xsl:template match="tence">
35         ,<i><xsl:apply-templates/></i>
36 </xsl:template>
37
38 <xsl:template match="def">
39         ,(<xsl:apply-templates/>)
40 </xsl:template>
41
42 <xsl:template match="ex">
43         ,"<xsl:apply-templates/>"
44 </xsl:template>
45
46 <xsl:template match="c">
47         <xsl:variable name="atr" select="@c"/>
48         <font color="{$atr}"> <xsl:apply-templates/> </font>
49 </xsl:template>
50
51 </xsl:stylesheet>