Mercurial > dive4elements > river
comparison flys-aft/contrib/dips2html.xsl @ 5454:662bcb3bdfd7
AFT/DIPS: Added simple XSL transformation to turn DIPS.xml into HTML too be more readable.
author | Sascha L. Teichmann <teichmann@intevation.de> |
---|---|
date | Wed, 27 Mar 2013 12:23:41 +0100 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
5453:303701ab73c6 | 5454:662bcb3bdfd7 |
---|---|
1 <?xml version="1.0"?> | |
2 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:html="http://www.w3.org/1999/xhtml" version="1.0" exclude-result-prefixes="html"> | |
3 <xsl:output method="html"/> | |
4 <xsl:template name="out"> | |
5 <xsl:param name="value"/> | |
6 <xsl:choose> | |
7 <xsl:when test="$value = ''">-/-</xsl:when> | |
8 <xsl:otherwise> | |
9 <xsl:value-of select="$value"/> | |
10 </xsl:otherwise> | |
11 </xsl:choose> | |
12 </xsl:template> | |
13 <xsl:template match="PEGELSTATION"> | |
14 <tr> | |
15 <td> | |
16 <xsl:value-of select="@NAME"/> | |
17 </td> | |
18 <td> | |
19 <xsl:value-of select="@NUMMER"/> | |
20 </td> | |
21 <td> | |
22 <xsl:call-template name="out"> | |
23 <xsl:with-param name="value" select="@HOCHWERT"/> | |
24 </xsl:call-template> | |
25 </td> | |
26 <td> | |
27 <xsl:call-template name="out"> | |
28 <xsl:with-param name="value" select="@TK_BLATT"/> | |
29 </xsl:call-template> | |
30 </td> | |
31 <td> | |
32 <xsl:call-template name="out"> | |
33 <xsl:with-param name="value" select="@BETREIBER"/> | |
34 </xsl:call-template> | |
35 </td> | |
36 <td> | |
37 <xsl:call-template name="out"> | |
38 <xsl:with-param name="value" select="@GEOBREITE"/> | |
39 </xsl:call-template> | |
40 </td> | |
41 <td> | |
42 <xsl:call-template name="out"> | |
43 <xsl:with-param name="value" select="@GEOLAENGE"/> | |
44 </xsl:call-template> | |
45 </td> | |
46 <td> | |
47 <xsl:call-template name="out"> | |
48 <xsl:with-param name="value" select="@GEWAESSER"/> | |
49 </xsl:call-template> | |
50 </td> | |
51 <td> | |
52 <xsl:call-template name="out"> | |
53 <xsl:with-param name="value" select="@GUELTIGAB"/> | |
54 </xsl:call-template> | |
55 </td> | |
56 <td> | |
57 <xsl:call-template name="out"> | |
58 <xsl:with-param name="value" select="@LAGESTATUS"/> | |
59 </xsl:call-template> | |
60 </td> | |
61 <td> | |
62 <xsl:call-template name="out"> | |
63 <xsl:with-param name="value" select="@RECHTSWERT"/> | |
64 </xsl:call-template> | |
65 </td> | |
66 <td> | |
67 <xsl:call-template name="out"> | |
68 <xsl:with-param name="value" select="@ABLESUNGBIS"/> | |
69 </xsl:call-template> | |
70 </td> | |
71 <td> | |
72 <xsl:call-template name="out"> | |
73 <xsl:with-param name="value" select="@ABLESUNGSEIT"/> | |
74 </xsl:call-template> | |
75 </td> | |
76 <td> | |
77 <xsl:call-template name="out"> | |
78 <xsl:with-param name="value" select="@STATIONIERUNG"/> | |
79 </xsl:call-template> | |
80 </td> | |
81 <td> | |
82 <xsl:call-template name="out"> | |
83 <xsl:with-param name="value" select="@EINGERICHTETAM"/> | |
84 </xsl:call-template> | |
85 </td> | |
86 <td> | |
87 <xsl:call-template name="out"> | |
88 <xsl:with-param name="value" select="@EINZUGSGEBIET_AEO"/> | |
89 </xsl:call-template> | |
90 </td> | |
91 <td> | |
92 <xsl:call-template name="out"> | |
93 <xsl:with-param name="value" select="@GEBIETSKENNZIFFER"/> | |
94 </xsl:call-template> | |
95 </td> | |
96 <td> | |
97 <xsl:call-template name="out"> | |
98 <xsl:with-param name="value" select="@KILOMETRIERUNG_AB"/> | |
99 </xsl:call-template> | |
100 </td> | |
101 <td> | |
102 <xsl:call-template name="out"> | |
103 <xsl:with-param name="value" select="@LAGE_AM_GEWAESSER"/> | |
104 </xsl:call-template> | |
105 </td> | |
106 <td> | |
107 <xsl:call-template name="out"> | |
108 <xsl:with-param name="value" select="@ENTFERNUNGMUENDUNG"/> | |
109 </xsl:call-template> | |
110 </td> | |
111 <td> | |
112 <xsl:call-template name="out"> | |
113 <xsl:with-param name="value" select="@KILOMETRIERUNGSRICHTUNG"/> | |
114 </xsl:call-template> | |
115 </td> | |
116 </tr> | |
117 <xsl:if test="string-length(@BESCHREIBUNG) > 0"> | |
118 <tr> | |
119 <td/> | |
120 <td colspan="21"> | |
121 <xsl:value-of select="@BESCHREIBUNG"/> | |
122 </td> | |
123 </tr> | |
124 </xsl:if> | |
125 </xsl:template> | |
126 <xsl:template match="/"> | |
127 <html> | |
128 <head> | |
129 <title>DiPs</title> | |
130 </head> | |
131 <body> | |
132 <table border="1" cellspacing="0" width="50%"> | |
133 <tr> | |
134 <th>Name</th> | |
135 <th>Nummer</th> | |
136 <th>Hochwert</th> | |
137 <th>TK-Blatt</th> | |
138 <th>Betreiber</th> | |
139 <th>Geo-Breite</th> | |
140 <th>Geo-Länge</th> | |
141 <th>Gewässer</th> | |
142 <th>Gültig ab</th> | |
143 <th>Lagestatus</th> | |
144 <th>Rechtswert</th> | |
145 <th>Ablesung seit</th> | |
146 <th>Ablesung bis</th> | |
147 <th>Stationierung</th> | |
148 <th>Eingerichtet am</th> | |
149 <th>Einzugsgebiet AEO</th> | |
150 <th>Gebietskennziffer</th> | |
151 <th>Kilometrierung ab</th> | |
152 <th>Lage am Gewässer</th> | |
153 <th>Entfernung zu Mündung</th> | |
154 <th>Kilometrierungsrichtung</th> | |
155 </tr> | |
156 <xsl:apply-templates select="/DIPSFLYS/STATIONEN"/> | |
157 </table> | |
158 </body> | |
159 </html> | |
160 </xsl:template> | |
161 <xsl:template match="text()"/> | |
162 </xsl:stylesheet> |