XSL - Xsl para transformar acentos en códigos html

 
Vista:

Xsl para transformar acentos en códigos html

Publicado por Krusen (2 intervenciones) el 15/12/2004 13:28:58
Hola, estoy un poco desesperado, necesito un xsl que transforme los acentos y caracteres especiales en sus códigos correspondientes. Por ejemplo: el caracter á me lo transforme en é en el documento final.
(No me sirven los character-map de XSL 2.0)

Saludos y gracias adelantadas
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder

RE:Xsl para transformar acentos en códigos html

Publicado por Krusen (2 intervenciones) el 19/12/2004 01:55:13
He encontrado una solución, gracias a la librería jtidy, no necesito xsl para realizar dicha translación, ésta librería convierte los acentos (caracteres especiales) en su correspondiente código html --> &#233 etc...., como en mi caso lo necesitaba en un servlet, queda de la siguiente forma:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
......
PrintWriter out = response.getWriter();
 
XMLDocument xDoc .....
......
ByteArrayOutputStream out2 = new ByteArrayOutputStream();
ByteArrayOutputStream out3 = new ByteArrayOutputStream();
xDoc.print(out2);
Tidy tidy = new Tidy(); // obtain a new Tidy instance
tidy.setXmlTags(true);
tidy.setXmlOut(true);
tidy.parse(new ByteArrayInputStream(out2.toByteArray()), out3);
out.print(out3.toString() );
......

Saludos
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por lilian (2 intervenciones) el 17/01/2011 00:05:25
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<?xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!--  localized strings
  -->
  <xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
  <xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
  <xsl:variable name="ColumnHeader_From">De</xsl:variable>
  <xsl:variable name="ColumnHeader_To">Para</xsl:variable>
  <xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!--  variables
  -->
  <xsl:variable name="Debug">0</xsl:variable>
  <xsl:variable name="TableStyle">font-family:Segoe UI; font-size:75%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
  <xsl:variable name="GutterStyle">width:2ex</xsl:variable>
  <xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
  <xsl:variable name="UseZebraStripe">1</xsl:variable>
  <xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
  <xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
  Message Log for
  <xsl:value-of select="@LogonName" />
  <xsl:if test="$Debug = 1">(Debug)</xsl:if>
  </title>
- <xsl:if test="$Debug = 1">
  <span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por ricardo (1 intervención) el 11/01/2009 00:47:24
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
<?xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!--  localized strings
  -->
  <xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
  <xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
  <xsl:variable name="ColumnHeader_From">De</xsl:variable>
  <xsl:variable name="ColumnHeader_To">Para</xsl:variable>
  <xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!--  variables
  -->
  <xsl:variable name="Debug">0</xsl:variable>
  <xsl:variable name="TableStyle">font-family:Verdana; font-size:67%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
  <xsl:variable name="GutterStyle">width:2ex</xsl:variable>
  <xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
  <xsl:variable name="UseZebraStripe">1</xsl:variable>
  <xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
  <xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
  Message Log for
  <xsl:value-of select="@LogonName" />
  <xsl:if test="$Debug = 1">(Debug)</xsl:if>
  </title>
- <xsl:if test="$Debug = 1">
  <span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
  <hr />
  </xsl:if>
  </head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
  <col style="vertical-align:top; width:5ex;" />
  <col style="{$GutterStyle}" />
  </xsl:if>
  <col style="width:16ex;" />
  <col style="{$GutterStyle}" />
  <col style="width:16ex;" />
  <col style="{$GutterStyle}" />
  <col style="width:21ex;" />
  <col style="{$GutterStyle}" />
  <col style="width:21ex;" />
  <col style="{$GutterStyle}" />
  <col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
  <th style="{$HeaderStyle}">SID</th>
  <th />
  </xsl:if>
- <th style="{$HeaderStyle}">
  <xsl:value-of select="$ColumnHeader_Date" />
  </th>
  <th />
- <th style="{$HeaderStyle}">
  <xsl:value-of select="$ColumnHeader_Time" />
  </th>
  <th />
- <th style="{$HeaderStyle}">
  <xsl:value-of select="$ColumnHeader_From" />
  </th>
  <th />
- <th style="{$HeaderStyle}">
  <xsl:value-of select="$ColumnHeader_To" />
  </th>
  <th />
- <th style="{$HeaderStyle}">
  <xsl:value-of select="$ColumnHeader_Message" />
  </th>
  </tr>
  </thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!--  newest session first
  -->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
  <xsl:sort select="@SessionID" order="descending" data-type="number" />
  <xsl:sort select="@DateTime" order="ascending" />
  </xsl:apply-templates>
  </xsl:when>
- <!--  oldest session first
  -->
- <xsl:otherwise>
- <xsl:apply-templates>
  <xsl:sort select="@SessionID" order="ascending" data-type="number" />
  <xsl:sort select="@DateTime" order="ascending" />
  </xsl:apply-templates>
  </xsl:otherwise>
  </xsl:choose>
  </tbody>
  </table>
  </body>
  </html>
  </xsl:template>
- <xsl:template match="Message">
- <tr>
  <xsl:call-template name="CommonMessageProcessing" />
- <td>
  <xsl:apply-templates select="From/User" />
  </td>
  <td />
- <td>
  <xsl:apply-templates select="To/User" />
  </td>
  <td />
- <td>
- <span>
- <xsl:attribute name="style">
  <xsl:value-of select="Text/@Style" />
  </xsl:attribute>
  <xsl:value-of select="Text" />
  </span>
  </td>
  </tr>
  </xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
  <xsl:call-template name="CommonMessageProcessing" />
  <td />
- <!--  From
  -->
  <td />
  <td />
- <!--  To
  -->
  <td />
- <td>
- <span>
- <xsl:attribute name="style">
  <xsl:value-of select="Text/@Style" />
  </xsl:attribute>
  <xsl:value-of select="Text" />
  </span>
  </td>
  </tr>
  </xsl:template>
- <xsl:template match="User">
- <!--  add a comma before all but the first user
  -->
  <xsl:if test="position() != 1">,</xsl:if>
  <xsl:value-of select="@FriendlyName" />
  </xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!--  zebra-stripe the sessions
  -->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
  <xsl:value-of select="$ZebraStripeStyle" />
  </xsl:attribute>
  </xsl:if>
  </xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
  <xsl:value-of select="@SessionID" />
  </td>%
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por jose gomez (1 intervención) el 03/05/2009 04:51:21
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!--  localized strings
  -->
  <xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
  <xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
  <xsl:variable name="ColumnHeader_From">De</xsl:variable>
  <xsl:variable name="ColumnHeader_To">Para</xsl:variable>
  <xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!--  variables
  -->
  <xsl:variable name="Debug">0</xsl:variable>
  <xsl:variable name="TableStyle">font-family:MS Shell Dlg 2; font-size:67%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
  <xsl:variable name="GutterStyle">width:2ex</xsl:variable>
  <xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
  <xsl:variable name="UseZebraStripe">1</xsl:variable>
  <xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
  <xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
  Message Log for
  <xsl:value-of select="@LogonName" />
  <xsl:if test="$Debug = 1">(Debug)</xsl:if>
  </title>
- <xsl:if test="$Debug = 1">
  <span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
  <hr />
  </xsl:if>
  </head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
  <col style="vertical-align:top; width:5ex;" />
  <col style="{$GutterStyle}" />
  </xsl:if>
  <col style="width:16ex;" />
  <col style="{$GutterStyle}" />
  <col style="width:16ex;" />
  <col style="{$GutterStyle}" />
  <col style="width:21ex;" />
  <col style="{$GutterStyle}" />
  <col style="width:21ex;" />
  <col style="{$GutterStyle}" />
  <col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
  <th style="{$HeaderStyle}">SID</th>
  <th />
  </xsl:if>
- <th style="{$HeaderStyle}">
  <xsl:value-of select="$ColumnHeader_Date" />
  </th>
  <th />
- <th style="{$HeaderStyle}">
  <xsl:value-of select="$ColumnHeader_Time" />
  </th>
  <th />
- <th style="{$HeaderStyle}">
  <xsl:value-of select="$ColumnHeader_From" />
  </th>
  <th />
- <th style="{$HeaderStyle}">
  <xsl:value-of select="$ColumnHeader_To" />
  </th>
  <th />
- <th style="{$HeaderStyle}">
  <xsl:value-of select="$ColumnHeader_Message" />
  </th>
  </tr>
  </thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!--  newest session first
  -->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
  <xsl:sort select="@SessionID" order="descending" data-type="number" />
  <xsl:sort select="@DateTime" order="ascending" />
  </xsl:apply-templates>
  </xsl:when>
- <!--  oldest session first
  -->
- <xsl:otherwise>
- <xsl:apply-templates>
  <xsl:sort select="@SessionID" order="ascending" data-type="number" />
  <xsl:sort select="@DateTime" order="ascending" />
  </xsl:apply-templates>
  </xsl:otherwise>
  </xsl:choose>
  </tbody>
  </table>
  </body>
  </html>
  </xsl:template>
- <xsl:template match="Message">
- <tr>
  <xsl:call-template name="CommonMessageProcessing" />
- <td>
  <xsl:apply-templates select="From/User" />
  </td>
  <td />
- <td>
  <xsl:apply-templates select="To/User" />
  </td>
  <td />
- <td>
- <span>
- <xsl:attribute name="style">
  <xsl:value-of select="Text/@Style" />
  </xsl:attribute>
  <xsl:value-of select="Text" />
  </span>
  </td>
  </tr>
  </xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
  <xsl:call-template name="CommonMessageProcessing" />
  <td />
- <!--  From
  -->
  <td />
  <td />
- <!--  To
  -->
  <td />
- <td>
- <span>
- <xsl:attribute name="style">
  <xsl:value-of select="Text/@Style" />
  </xsl:attribute>
  <xsl:value-of select="Text" />
  </span>
  </td>
  </tr>
  </xsl:template>
- <xsl:template match="User">
- <!--  add a comma before all but the first user
  -->
  <xsl:if test="position() != 1">,</xsl:if>
  <xsl:value-of select="@FriendlyName" />
  </xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!--  zebra-stripe the sessions
  -->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
  <xsl:value-of select="$ZebraStripeStyle" />
  </xsl:attribute>
  </xsl:if>
  </xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
  <xsl:value-of select="@SessionID" />
  </td>
  <td />
  </xsl:if>
- <td>
  <xsl:value-of select="@Date" />
  </td>
  <td />
- <td>
  <xsl:value-of select="@Time" />
  </td>
  <td />
  </xsl:template>
  </xsl:stylesheet>
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por carmen (1 intervención) el 12/05/2009 10:39:40
<?xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!-- localized strings
-->
<xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
<xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
<xsl:variable name="ColumnHeader_From">De</xsl:variable>
<xsl:variable name="ColumnHeader_To">Para</xsl:variable>
<xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!-- variables
-->
<xsl:variable name="Debug">0</xsl:variable>
<xsl:variable name="TableStyle">font-family:Segoe UI; font-size:75%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
<xsl:variable name="GutterStyle">width:2ex</xsl:variable>
<xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
<xsl:variable name="UseZebraStripe">1</xsl:variable>
<xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
<xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
Message Log for
<xsl:value-of select="@LogonName" />
<xsl:if test="$Debug = 1">(Debug)</xsl:if>
</title>
- <xsl:if test="$Debug = 1">
<span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
<hr />
</xsl:if>
</head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
<col style="vertical-align:top; width:5ex;" />
<col style="{$GutterStyle}" />
</xsl:if>
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
<th style="{$HeaderStyle}">SID</th>
<th />
</xsl:if>
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Date" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Time" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_From" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_To" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Message" />
</th>
</tr>
</thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!-- newest session first
-->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="descending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:when>
- <!-- oldest session first
-->
- <xsl:otherwise>
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="ascending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:otherwise>
</xsl:choose>
</tbody>
</table>
</body>
</html>
</xsl:template>
- <xsl:template match="Message">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
- <td>
<xsl:apply-templates select="From/User" />
</td>
<td />
- <td>
<xsl:apply-templates select="To/User" />
</td>
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
<td />
- <!-- From
-->
<td />
<td />
- <!-- To
-->
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="User">
- <!-- add a comma before all but the first user
-->
<xsl:if test="position() != 1">,</xsl:if>
<xsl:value-of select="@FriendlyName" />
</xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!-- zebra-stripe the sessions
-->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
<xsl:value-of select="$ZebraStripeStyle" />
</xsl:attribute>
</xsl:if>
</xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
<xsl:value-of select="@SessionID" />
</td>
<td />
</xsl:if>
- <td>
<xsl:value-of select="@Date" />
</td>
<td />
- <td>
<xsl:value-of select="@Time" />
</td>
<td />
</xsl:template>
</xsl:stylesheet>
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por anahi  (1 intervención) el 30/06/2009 06:17:18
<?xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!-- localized strings
-->
<xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
<xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
<xsl:variable name="ColumnHeader_From">De</xsl:variable>
<xsl:variable name="ColumnHeader_To">Para</xsl:variable>
<xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!-- variables
-->
<xsl:variable name="Debug">0</xsl:variable>
<xsl:variable name="TableStyle">font-family:Segoe UI; font-size:75%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
<xsl:variable name="GutterStyle">width:2ex</xsl:variable>
<xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
<xsl:variable name="UseZebraStripe">1</xsl:variable>
<xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
<xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
Message Log for
<xsl:value-of select="@LogonName" />
<xsl:if test="$Debug = 1">(Debug)</xsl:if>
</title>
- <xsl:if test="$Debug = 1">
<span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
<hr />
</xsl:if>
</head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
<col style="vertical-align:top; width:5ex;" />
<col style="{$GutterStyle}" />
</xsl:if>
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
<th style="{$HeaderStyle}">SID</th>
<th />
</xsl:if>
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Date" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Time" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_From" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_To" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Message" />
</th>
</tr>
</thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!-- newest session first
-->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="descending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:when>
- <!-- oldest session first
-->
- <xsl:otherwise>
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="ascending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:otherwise>
</xsl:choose>
</tbody>
</table>
</body>
</html>
</xsl:template>
- <xsl:template match="Message">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
- <td>
<xsl:apply-templates select="From/User" />
</td>
<td />
- <td>
<xsl:apply-templates select="To/User" />
</td>
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
<td />
- <!-- From
-->
<td />
<td />
- <!-- To
-->
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="User">
- <!-- add a comma before all but the first user
-->
<xsl:if test="position() != 1">,</xsl:if>
<xsl:value-of select="@FriendlyName" />
</xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!-- zebra-stripe the sessions
-->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
<xsl:value-of select="$ZebraStripeStyle" />
</xsl:attribute>
</xsl:if>
</xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
<xsl:value-of select="@SessionID" />
</td>
<td />
</xsl:if>
- <td>
<xsl:value-of select="@Date" />
</td>
<td />
- <td>
<xsl:value-of select="@Time" />
</td>
<td />
</xsl:template>
</xsl:stylesheet>
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por LUIS MIGUEL (1 intervención) el 23/10/2010 18:29:51
<?xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!-- localized strings
-->
<xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
<xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
<xsl:variable name="ColumnHeader_From">De</xsl:variable>
<xsl:variable name="ColumnHeader_To">Para</xsl:variable>
<xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!-- variables
-->
<xsl:variable name="Debug">0</xsl:variable>
<xsl:variable name="TableStyle">font-family:Segoe UI; font-size:75%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
<xsl:variable name="GutterStyle">width:2ex</xsl:variable>
<xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
<xsl:variable name="UseZebraStripe">1</xsl:variable>
<xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
<xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
Message Log for
<xsl:value-of select="@LogonName" />
<xsl:if test="$Debug = 1">(Debug)</xsl:if>
</title>
- <xsl:if test="$Debug = 1">
<span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
<hr />
</xsl:if>
</head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
<col style="vertical-align:top; width:5ex;" />
<col style="{$GutterStyle}" />
</xsl:if>
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
<th style="{$HeaderStyle}">SID</th>
<th />
</xsl:if>
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Date" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Time" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_From" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_To" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Message" />
</th>
</tr>
</thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!-- newest session first
-->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="descending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:when>
- <!-- oldest session first
-->
- <xsl:otherwise>
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="ascending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:otherwise>
</xsl:choose>
</tbody>
</table>
</body>
</html>
</xsl:template>
- <xsl:template match="Message">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
- <td>
<xsl:apply-templates select="From/User" />
</td>
<td />
- <td>
<xsl:apply-templates select="To/User" />
</td>
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
<td />
- <!-- From
-->
<td />
<td />
- <!-- To
-->
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="User">
- <!-- add a comma before all but the first user
-->
<xsl:if test="position() != 1">,</xsl:if>
<xsl:value-of select="@FriendlyName" />
</xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!-- zebra-stripe the sessions
-->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
<xsl:value-of select="$ZebraStripeStyle" />
</xsl:attribute>
</xsl:if>
</xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
<xsl:value-of select="@SessionID" />
</td>
<td />
</xsl:if>
- <td>
<xsl:value-of select="@Date" />
</td>
<td />
- <td>
<xsl:value-of select="@Time" />
</td>
<td />
</xsl:template>
</xsl:stylesheet>
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por miguel (1 intervención) el 30/08/2009 16:30:11
<?xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!-- localized strings
-->
<xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
<xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
<xsl:variable name="ColumnHeader_From">De</xsl:variable>
<xsl:variable name="ColumnHeader_To">Para</xsl:variable>
<xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!-- variables
-->
<xsl:variable name="Debug">0</xsl:variable>
<xsl:variable name="TableStyle">font-family:Segoe UI; font-size:75%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
<xsl:variable name="GutterStyle">width:2ex</xsl:variable>
<xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
<xsl:variable name="UseZebraStripe">1</xsl:variable>
<xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
<xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
Message Log for
<xsl:value-of select="@LogonName" />
<xsl:if test="$Debug = 1">(Debug)</xsl:if>
</title>
- <xsl:if test="$Debug = 1">
<span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
<hr />
</xsl:if>
</head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
<col style="vertical-align:top; width:5ex;" />
<col style="{$GutterStyle}" />
</xsl:if>
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
<th style="{$HeaderStyle}">SID</th>
<th />
</xsl:if>
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Date" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Time" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_From" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_To" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Message" />
</th>
</tr>
</thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!-- newest session first
-->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="descending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:when>
- <!-- oldest session first
-->
- <xsl:otherwise>
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="ascending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:otherwise>
</xsl:choose>
</tbody>
</table>
</body>
</html>
</xsl:template>
- <xsl:template match="Message">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
- <td>
<xsl:apply-templates select="From/User" />
</td>
<td />
- <td>
<xsl:apply-templates select="To/User" />
</td>
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
<td />
- <!-- From
-->
<td />
<td />
- <!-- To
-->
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="User">
- <!-- add a comma before all but the first user
-->
<xsl:if test="position() != 1">,</xsl:if>
<xsl:value-of select="@FriendlyName" />
</xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!-- zebra-stripe the sessions
-->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
<xsl:value-of select="$ZebraStripeStyle" />
</xsl:attribute>
</xsl:if>
</xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
<xsl:value-of select="@SessionID" />
</td>
<td />
</xsl:if>
- <td>
<xsl:value-of select="@Date" />
</td>
<td />
- <td>
<xsl:value-of select="@Time" />
</td>
<td />
</xsl:template>
</xsl:stylesheet>
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por martin (1 intervención) el 15/03/2010 06:15:46
<?xml version = "1.0" ?>
-- <xsl: stylesheet versión= "1,0" xmlns: xsl= "http://www.w3.org/1999/XSL/Transform">
-- <! -- cadenas localizadas
->
<xsl: variable nombre= "ColumnHeader_Date">Fecha</xsl: variable>
<xsl: variable nombre= "ColumnHeader_Time">Hora</xsl: variable>
<xsl: variable nombre= "ColumnHeader_From">De</xsl: variable>
<xsl: variable nombre= "ColumnHeader_To">Para</xsl: variable>
<xsl: variable nombre= "ColumnHeader_Message">Mensaje</xsl: variable>
-- <! -- variables
->
<xsl: variable nombre= "Depurar">0</xsl: variable>
<xsl: variable nombre= "TableStyle">font-family: Segoe interfaz de usuario; font-size: 75%; text-align: left; vertical-align: top; tabla de diseño: fijo</xsl: variable>
<xsl: variable nombre= "GutterStyle">width: 2ex</xsl: variable>
<xsl: variable nombre= "HeaderStyle">border-bottom: 1 negro sólido</xsl: variable>
<xsl: variable nombre= "UseZebraStripe">1</xsl: variable>
<xsl: variable nombre= "ZebraStripeStyle">background-color: # e0edff</xsl: variable>
<xsl: variable nombre= "MostRecentSessionFirst">0</xsl: variable>
-- <xsl: template coincidir= "Registrarse">
-- <html dir= "LTR">
-- <cabeza>
-- <Título>
Mensaje de registro de
<xsl: value-of Seleccione= "@ LogonName" />
<xsl: if prueba= "$ Debug = 1">(Depuración)</xsl: if>
</Título>
-- <xsl: if prueba= "$ Debug = 1">
<span estilo= "font-family: trebuchet ms; font-size: 120%">Versión de depuración</span>
<hr />
</xsl: if>
</cabeza>
-- <cuerpo estilo= "margin: 0">
-- <mesa ID= "BodyTable" estilo= "($ TableStyle)" cellspacing= "0">
-- <xsl: if prueba= "$ Debug = 1">
<col estilo= "vertical-align: top; width: 5EX;" />
<col estilo= "($ GutterStyle)" />
</xsl: if>
<col estilo= "width: 16ex;" />
<col estilo= "($ GutterStyle)" />
<col estilo= "width: 16ex;" />
<col estilo= "($ GutterStyle)" />
<col estilo= "width: 21ex;" />
<col estilo= "($ GutterStyle)" />
<col estilo= "width: 21ex;" />
<col estilo= "($ GutterStyle)" />
<col estilo= "width: 70ex;" />
-- <thead>
-- <tr>
-- <xsl: if prueba= "$ Debug = 1">
<o estilo= "($ HeaderStyle)">SID</o>
<o />
</xsl: if>
-- <o estilo= "($ HeaderStyle)">
<xsl: value-of Seleccione= "$ ColumnHeader_Date" />
</o>
<o />
-- <o estilo= "($ HeaderStyle)">
<xsl: value-of Seleccione= "$ ColumnHeader_Time" />
</o>
<o />
-- <o estilo= "($ HeaderStyle)">
<xsl: value-of Seleccione= "ColumnHeader_From $" />
</o>
<o />
-- <o estilo= "($ HeaderStyle)">
<xsl: value-of Seleccione= "ColumnHeader_To $" />
</o>
<o />
-- <o estilo= "($ HeaderStyle)">
<xsl: value-of Seleccione= "ColumnHeader_Message $" />
</o>
</tr>
</thead>
-- <tbody estilo= "vertical-align: top">
-- <xsl: choose>
-- <! -- último período de sesiones
->
-- <xsl: when prueba= "MostRecentSessionFirst $ = 1">
-- <xsl: apply-templates>
<xsl: sort Seleccione= "@ SessionID" orden= "descendente" tipo de datos= "número" />
<xsl: sort Seleccione= "@ DateTime" orden= "ascendente" />
</xsl: apply-templates>
</xsl: when>
-- <! -- más antiguo primer período de sesiones
->
-- <xsl: otherwise>
-- <xsl: apply-templates>
<xsl: sort Seleccione= "@ SessionID" orden= "ascendente" tipo de datos= "número" />
<xsl: sort Seleccione= "@ DateTime" orden= "ascendente" />
</xsl: apply-templates>
</xsl: otherwise>
</xsl: choose>
</tbody>
</mesa>
</cuerpo>
</html>
</xsl: template>
-- <xsl: template coincidir= "Mensaje">
-- <tr>
<xsl: call-template nombre= "CommonMessageProcessing" />
-- <td>
<xsl: apply-templates Seleccione= "De / usuario" />
</td>
<td />
-- <td>
<xsl: apply-templates Seleccione= "A / usuario" />
</td>
<td />
-- <td>
-- <span>
-- <xsl: attribute nombre= "estilo">
<xsl: value-of Seleccione= "Texto / @ Estilo" />
</xsl: attribute>
<xsl: value-of Seleccione= "Texto" />
</span>
</td>
</tr>
</xsl: template>
-- <xsl: template coincidir= "Invitación | InvitationResponse | Join | Deja">
-- <tr>
<xsl: call-template nombre= "CommonMessageProcessing" />
<td />
-- <! -- Desde
->
<td />
<td />
-- <! -- Para
->
<td />
-- <td>
-- <span>
-- <xsl: attribute nombre= "estilo">
<xsl: value-of Seleccione= "Texto / @ Estilo" />
</xsl: attribute>
<xsl: value-of Seleccione= "Texto" />
</span>
</td>
</tr>
</xsl: template>
-- <xsl: template coincidir= "Usuario">
-- <! -- añadir una coma antes de todos, pero el primer usuario
->
<xsl: if prueba= "posición ()! = 1">,</xsl: if>
<xsl: value-of Seleccione= "@ FriendlyName" />
</xsl: template>
-- <xsl: template nombre= "CommonMessageProcessing">
-- <! -- cebra raya los períodos de sesiones
->
-- <xsl: if prueba= "$ UseZebraStripe = 1">
-- <xsl: if prueba= "(@ SessionID mod 2) = 1">
-- <xsl: attribute nombre= "estilo">
<xsl: value-of Seleccione= "$ ZebraStripeStyle" />
</xsl: attribute>
</xsl: if>
</xsl: if>
-- <xsl: if prueba= "$ Debug = 1">
-- <td>
<xsl: value-of Seleccione= "@ SessionID" />
</td>
<td />
</xsl: if>
-- <td>
<xsl: value-of Seleccione= "@ Fecha" />
</td>
<td />
-- <td>
<xsl: value-of Seleccione= "@ Tiempo" />
</td>
<td />
</xsl: template>
</xsl: stylesheet>
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por ver (1 intervención) el 29/03/2010 02:07:31
xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!-- localized strings
-->
<xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
<xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
<xsl:variable name="ColumnHeader_From">De</xsl:variable>
<xsl:variable name="ColumnHeader_To">Para</xsl:variable>
<xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!-- variables
-->
<xsl:variable name="Debug">0</xsl:variable>
<xsl:variable name="TableStyle">font-family:Segoe UI; font-size:75%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
<xsl:variable name="GutterStyle">width:2ex</xsl:variable>
<xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
<xsl:variable name="UseZebraStripe">1</xsl:variable>
<xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
<xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
Message Log for
<xsl:value-of select="@LogonName" />
<xsl:if test="$Debug = 1">(Debug)</xsl:if>
</title>
- <xsl:if test="$Debug = 1">
<span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
<hr />
</xsl:if>
</head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
<col style="vertical-align:top; width:5ex;" />
<col style="{$GutterStyle}" />
</xsl:if>
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
<th style="{$HeaderStyle}">SID</th>
<th />
</xsl:if>
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Date" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Time" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_From" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_To" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Message" />
</th>
</tr>
</thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!-- newest session first
-->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="descending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:when>
- <!-- oldest session first
-->
- <xsl:otherwise>
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="ascending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:otherwise>
</xsl:choose>
</tbody>
</table>
</body>
</html>
</xsl:template>
- <xsl:template match="Message">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
- <td>
<xsl:apply-templates select="From/User" />
</td>
<td />
- <td>
<xsl:apply-templates select="To/User" />
</td>
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
<td />
- <!-- From
-->
<td />
<td />
- <!-- To
-->
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="User">
- <!-- add a comma before all but the first user
-->
<xsl:if test="position() != 1">,</xsl:if>
<xsl:value-of select="@FriendlyName" />
</xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!-- zebra-stripe the sessions
-->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
<xsl:value-of select="$ZebraStripeStyle" />
</xsl:attribute>
</xsl:if>
</xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
<xsl:value-of select="@SessionID" />
</td>
<td />
</xsl:if>
- <td>
<xsl:value-of select="@Date" />
</td>
<td />
- <td>
<xsl:value-of select="@Time" />
</td>
<td />
</xsl:template>
</xsl:stylesheet>
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por miguel (1 intervención) el 02/01/2011 00:49:03
Fecha
Hora
De
Para
Mensaje
0
font-family:Segoe UI; font-size:75%; text-align:left; vertical-align:top; table-layout:fixed
width:2ex
border-bottom:1 solid black
1
background-color:#e0edff
0


Message Log for

(Debug)

Debug Version











SID









































xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!-- localized strings
-->
<xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
<xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
<xsl:variable name="ColumnHeader_From">De</xsl:variable>
<xsl:variable name="ColumnHeader_To">Para</xsl:variable>
<xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!-- variables
-->
<xsl:variable name="Debug">0</xsl:variable>
<xsl:variable name="TableStyle">font-family:Segoe UI; font-size:75%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
<xsl:variable name="GutterStyle">width:2ex</xsl:variable>
<xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
<xsl:variable name="UseZebraStripe">1</xsl:variable>
<xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
<xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
Message Log for
<xsl:value-of select="@LogonName" />
<xsl:if test="$Debug = 1">(Debug)</xsl:if>
</title>
- <xsl:if test="$Debug = 1">
<span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
<hr />
</xsl:if>
</head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
<col style="vertical-align:top; width:5ex;" />
<col style="{$GutterStyle}" />
</xsl:if>
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
<th style="{$HeaderStyle}">SID</th>
<th />
</xsl:if>
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Date" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Time" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_From" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_To" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Message" />
</th>
</tr>
</thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!-- newest session first
-->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="descending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:when>
- <!-- oldest session first
-->
- <xsl:otherwise>
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="ascending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:otherwise>
</xsl:choose>
</tbody>
</table>
</body>
</html>
</xsl:template>
- <xsl:template match="Message">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
- <td>
<xsl:apply-templates select="From/User" />
</td>
<td />
- <td>
<xsl:apply-templates select="To/User" />
</td>
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
<td />
- <!-- From
-->
<td />
<td />
- <!-- To
-->
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="User">
- <!-- add a comma before all but the first user
-->
<xsl:if test="position() != 1">,</xsl:if>
<xsl:value-of select="@FriendlyName" />
</xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!-- zebra-stripe the sessions
-->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
<xsl:value-of select="$ZebraStripeStyle" />
</xsl:attribute>
</xsl:if>
</xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
<xsl:value-of select="@SessionID" />
</td>
<td />
</xsl:if>
- <td>
<xsl:value-of select="@Date" />
</td>
<td />
- <td>
<xsl:value-of select="@Time" />
</td>
<td />
</xsl:template>
</xsl:stylesheet>
,
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por JJ (1 intervención) el 18/08/2010 05:33:13
<?xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!-- localized strings
-->
<xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
<xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
<xsl:variable name="ColumnHeader_From">De</xsl:variable>
<xsl:variable name="ColumnHeader_To">Para</xsl:variable>
<xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!-- variables
-->
<xsl:variable name="Debug">0</xsl:variable>
<xsl:variable name="TableStyle">font-family:Segoe UI; font-size:75%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
<xsl:variable name="GutterStyle">width:2ex</xsl:variable>
<xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
<xsl:variable name="UseZebraStripe">1</xsl:variable>
<xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
<xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
Message Log for
<xsl:value-of select="@LogonName" />
<xsl:if test="$Debug = 1">(Debug)</xsl:if>
</title>
- <xsl:if test="$Debug = 1">
<span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
<hr />
</xsl:if>
</head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
<col style="vertical-align:top; width:5ex;" />
<col style="{$GutterStyle}" />
</xsl:if>
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
<th style="{$HeaderStyle}">SID</th>
<th />
</xsl:if>
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Date" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Time" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_From" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_To" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Message" />
</th>
</tr>
</thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!-- newest session first
-->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="descending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:when>
- <!-- oldest session first
-->
- <xsl:otherwise>
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="ascending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:otherwise>
</xsl:choose>
</tbody>
</table>
</body>
</html>
</xsl:template>
- <xsl:template match="Message">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
- <td>
<xsl:apply-templates select="From/User" />
</td>
<td />
- <td>
<xsl:apply-templates select="To/User" />
</td>
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
<td />
- <!-- From
-->
<td />
<td />
- <!-- To
-->
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="User">
- <!-- add a comma before all but the first user
-->
<xsl:if test="position() != 1">,</xsl:if>
<xsl:value-of select="@FriendlyName" />
</xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!-- zebra-stripe the sessions
-->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
<xsl:value-of select="$ZebraStripeStyle" />
</xsl:attribute>
</xsl:if>
</xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
<xsl:value-of select="@SessionID" />
</td>
<td />
</xsl:if>
- <td>
<xsl:value-of select="@Date" />
</td>
<td />
- <td>
<xsl:value-of select="@Time" />
</td>
<td />
</xsl:template>
</xsl:stylesheet>
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por estefania (1 intervención) el 27/08/2010 18:47:59
<?xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!-- localized strings
-->
<xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
<xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
<xsl:variable name="ColumnHeader_From">De</xsl:variable>
<xsl:variable name="ColumnHeader_To">Para</xsl:variable>
<xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!-- variables
-->
<xsl:variable name="Debug">0</xsl:variable>
<xsl:variable name="TableStyle">font-family:Segoe UI; font-size:75%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
<xsl:variable name="GutterStyle">width:2ex</xsl:variable>
<xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
<xsl:variable name="UseZebraStripe">1</xsl:variable>
<xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
<xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
Message Log for
<xsl:value-of select="@LogonName" />
<xsl:if test="$Debug = 1">(Debug)</xsl:if>
</title>
- <xsl:if test="$Debug = 1">
<span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
<hr />
</xsl:if>
</head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
<col style="vertical-align:top; width:5ex;" />
<col style="{$GutterStyle}" />
</xsl:if>
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
<th style="{$HeaderStyle}">SID</th>
<th />
</xsl:if>
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Date" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Time" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_From" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_To" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Message" />
</th>
</tr>
</thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!-- newest session first
-->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="descending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:when>
- <!-- oldest session first
-->
- <xsl:otherwise>
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="ascending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:otherwise>
</xsl:choose>
</tbody>
</table>
</body>
</html>
</xsl:template>
- <xsl:template match="Message">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
- <td>
<xsl:apply-templates select="From/User" />
</td>
<td />
- <td>
<xsl:apply-templates select="To/User" />
</td>
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
<td />
- <!-- From
-->
<td />
<td />
- <!-- To
-->
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="User">
- <!-- add a comma before all but the first user
-->
<xsl:if test="position() != 1">,</xsl:if>
<xsl:value-of select="@FriendlyName" />
</xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!-- zebra-stripe the sessions
-->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
<xsl:value-of select="$ZebraStripeStyle" />
</xsl:attribute>
</xsl:if>
</xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
<xsl:value-of select="@SessionID" />
</td>
<td />
</xsl:if>
- <td>
<xsl:value-of select="@Date" />
</td>
<td />
- <td>
<xsl:value-of select="@Time" />
</td>
<td />
</xsl:template>
</xsl:stylesheet>
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por mirko (1 intervención) el 30/12/2010 08:22:36
<?xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!-- localized strings
-->
<xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
<xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
<xsl:variable name="ColumnHeader_From">De</xsl:variable>
<xsl:variable name="ColumnHeader_To">Para</xsl:variable>
<xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!-- variables
-->
<xsl:variable name="Debug">0</xsl:variable>
<xsl:variable name="TableStyle">font-family:Verdana; font-size:67%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
<xsl:variable name="GutterStyle">width:2ex</xsl:variable>
<xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
<xsl:variable name="UseZebraStripe">1</xsl:variable>
<xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
<xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
Message Log for
<xsl:value-of select="@LogonName" />
<xsl:if test="$Debug = 1">(Debug)</xsl:if>
</title>
- <xsl:if test="$Debug = 1">
<span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
<hr />
</xsl:if>
</head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
<col style="vertical-align:top; width:5ex;" />
<col style="{$GutterStyle}" />
</xsl:if>
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
<th style="{$HeaderStyle}">SID</th>
<th />
</xsl:if>
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Date" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Time" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_From" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_To" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Message" />
</th>
</tr>
</thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!-- newest session first
-->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="descending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:when>
- <!-- oldest session first
-->
- <xsl:otherwise>
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="ascending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:otherwise>
</xsl:choose>
</tbody>
</table>
</body>
</html>
</xsl:template>
- <xsl:template match="Message">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
- <td>
<xsl:apply-templates select="From/User" />
</td>
<td />
- <td>
<xsl:apply-templates select="To/User" />
</td>
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
<td />
- <!-- From
-->
<td />
<td />
- <!-- To
-->
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="User">
- <!-- add a comma before all but the first user
-->
<xsl:if test="position() != 1">,</xsl:if>
<xsl:value-of select="@FriendlyName" />
</xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!-- zebra-stripe the sessions
-->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
<xsl:value-of select="$ZebraStripeStyle" />
</xsl:attribute>
</xsl:if>
</xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
<xsl:value-of select="@SessionID" />
</td>%
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por carmen (1 intervención) el 24/02/2011 00:56:47
Me gustaría que alguien me ayudara a descifrar todos los códigos que aparecen en mis arcivos les doy las gracias.
recibid<?xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!--
localized strings
-->
<xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
<xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
<xsl:variable name="ColumnHeader_From">De</xsl:variable>
<xsl:variable name="ColumnHeader_To">Para</xsl:variable>
<xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!--
variables
-->
<xsl:variable name="Debug">0</xsl:variable>
<xsl:variable name="TableStyle">font-family:Segoe UI; font-size:75%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
<xsl:variable name="GutterStyle">width:2ex</xsl:variable>
<xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
<xsl:variable name="UseZebraStripe">1</xsl:variable>
<xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
<xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
Message Log for
<xsl:value-of select="@LogonName" />
<xsl:if test="$Debug = 1">(Debug)</xsl:if>
</title>
- <xsl:if test="$Debug = 1">
<span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
<hr />
</xsl:if>
</head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
<col style="vertical-align:top; width:5ex;" />
<col style="{$GutterStyle}" />
</xsl:if>
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
<th style="{$HeaderStyle}">SID</th>
<th />
</xsl:if>
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Date" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Time" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_From" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_To" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Message" />
</th>
</tr>
</thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!--
newest session first
-->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="descending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:when>
- <!--
oldest session first
-->
- <xsl:otherwise>
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="ascending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:otherwise>
</xsl:choose>
</tbody>
</table>
</body>
</html>
</xsl:template>
- <xsl:template match="Message">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
- <td>
<xsl:apply-templates select="From/User" />
</td>
<td />
- <td>
<xsl:apply-templates select="To/User" />
</td>
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
<td />
- <!--
From
-->
<td />
<td />
- <!--
To
-->
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="User">
- <!--
add a comma before all but the first user
-->
<xsl:if test="position() != 1">,</xsl:if>
<xsl:value-of select="@FriendlyName" />
</xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!--
zebra-stripe the sessions
-->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
<xsl:value-of select="$ZebraStripeStyle" />
</xsl:attribute>
</xsl:if>
</xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
<xsl:value-of select="@SessionID" />
</td>
<td />
</xsl:if>
- <td>
<xsl:value-of select="@Date" />
</td>
<td />
- <td>
<xsl:value-of select="@Time" />
</td>
<td />
</xsl:template>
</xsl:stylesheet>

os
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por juan carlos (1 intervención) el 07/07/2009 08:35:24
<?xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!-- localized strings
-->
<xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
<xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
<xsl:variable name="ColumnHeader_From">De</xsl:variable>
<xsl:variable name="ColumnHeader_To">Para</xsl:variable>
<xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!-- variables
-->
<xsl:variable name="Debug">0</xsl:variable>
<xsl:variable name="TableStyle">font-family:MS Shell Dlg 2; font-size:67%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
<xsl:variable name="GutterStyle">width:2ex</xsl:variable>
<xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
<xsl:variable name="UseZebraStripe">1</xsl:variable>
<xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
<xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
Message Log for
<xsl:value-of select="@LogonName" />
<xsl:if test="$Debug = 1">(Debug)</xsl:if>
</title>
- <xsl:if test="$Debug = 1">
<span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
<hr />
</xsl:if>
</head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
<col style="vertical-align:top; width:5ex;" />
<col style="{$GutterStyle}" />
</xsl:if>
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
<th style="{$HeaderStyle}">SID</th>
<th />
</xsl:if>
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Date" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Time" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_From" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_To" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Message" />
</th>
</tr>
</thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!-- newest session first
-->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="descending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:when>
- <!-- oldest session first
-->
- <xsl:otherwise>
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="ascending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:otherwise>
</xsl:choose>
</tbody>
</table>
</body>
</html>
</xsl:template>
- <xsl:template match="Message">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
- <td>
<xsl:apply-templates select="From/User" />
</td>
<td />
- <td>
<xsl:apply-templates select="To/User" />
</td>
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
<td />
- <!-- From
-->
<td />
<td />
- <!-- To
-->
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="User">
- <!-- add a comma before all but the first user
-->
<xsl:if test="position() != 1">,</xsl:if>
<xsl:value-of select="@FriendlyName" />
</xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!-- zebra-stripe the sessions
-->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
<xsl:value-of select="$ZebraStripeStyle" />
</xsl:attribute>
</xsl:if>
</xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
<xsl:value-of select="@SessionID" />
</td>
<td />
</xsl:if>
- <td>
<xsl:value-of select="@Date" />
</td>
<td />
- <td>
<xsl:value-of select="@Time" />
</td>
<td />
</xsl:template>
</xsl:stylesheet>
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por alexis (1 intervención) el 07/06/2009 23:53:34
<?xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!-- localized strings
-->
<xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
<xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
<xsl:variable name="ColumnHeader_From">De</xsl:variable>
<xsl:variable name="ColumnHeader_To">Para</xsl:variable>
<xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!-- variables
-->
<xsl:variable name="Debug">0</xsl:variable>
<xsl:variable name="TableStyle">font-family:Segoe UI; font-size:75%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
<xsl:variable name="GutterStyle">width:2ex</xsl:variable>
<xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
<xsl:variable name="UseZebraStripe">1</xsl:variable>
<xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
<xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
Message Log for
<xsl:value-of select="@LogonName" />
<xsl:if test="$Debug = 1">(Debug)</xsl:if>
</title>
- <xsl:if test="$Debug = 1">
<span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
<hr />
</xsl:if>
</head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
<col style="vertical-align:top; width:5ex;" />
<col style="{$GutterStyle}" />
</xsl:if>
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
<th style="{$HeaderStyle}">SID</th>
<th />
</xsl:if>
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Date" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Time" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_From" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_To" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Message" />
</th>
</tr>
</thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!-- newest session first
-->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="descending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:when>
- <!-- oldest session first
-->
- <xsl:otherwise>
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="ascending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:otherwise>
</xsl:choose>
</tbody>
</table>
</body>
</html>
</xsl:template>
- <xsl:template match="Message">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
- <td>
<xsl:apply-templates select="From/User" />
</td>
<td />
- <td>
<xsl:apply-templates select="To/User" />
</td>
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
<td />
- <!-- From
-->
<td />
<td />
- <!-- To
-->
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="User">
- <!-- add a comma before all but the first user
-->
<xsl:if test="position() != 1">,</xsl:if>
<xsl:value-of select="@FriendlyName" />
</xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!-- zebra-stripe the sessions
-->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
<xsl:value-of select="$ZebraStripeStyle" />
</xsl:attribute>
</xsl:if>
</xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
<xsl:value-of select="@SessionID" />
</td>
<td />
</xsl:if>
- <td>
<xsl:value-of select="@Date" />
</td>
<td />
- <td>
<xsl:value-of select="@Time" />
</td>
<td />
</xsl:template>
</xsl:stylesheet>
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por marife (1 intervención) el 11/05/2010 10:44:29
http://www.w3.org/1999/XSL/Transform">
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por Luis Antonio Banda (2 intervenciones) el 22/05/2010 17:41:09
<?xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!-- localized strings
-->
<xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
<xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
<xsl:variable name="ColumnHeader_From">De</xsl:variable>
<xsl:variable name="ColumnHeader_To">Para</xsl:variable>
<xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!-- variables
-->
<xsl:variable name="Debug">0</xsl:variable>
<xsl:variable name="TableStyle">font-family:Segoe UI; font-size:75%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
<xsl:variable name="GutterStyle">width:2ex</xsl:variable>
<xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
<xsl:variable name="UseZebraStripe">1</xsl:variable>
<xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
<xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
Message Log for
<xsl:value-of select="@LogonName" />
<xsl:if test="$Debug = 1">(Debug)</xsl:if>
</title>
- <xsl:if test="$Debug = 1">
<span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
<hr />
</xsl:if>
</head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
<col style="vertical-align:top; width:5ex;" />
<col style="{$GutterStyle}" />
</xsl:if>
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
<th style="{$HeaderStyle}">SID</th>
<th />
</xsl:if>
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Date" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Time" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_From" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_To" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Message" />
</th>
</tr>
</thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!-- newest session first
-->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="descending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:when>
- <!-- oldest session first
-->
- <xsl:otherwise>
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="ascending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:otherwise>
</xsl:choose>
</tbody>
</table>
</body>
</html>
</xsl:template>
- <xsl:template match="Message">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
- <td>
<xsl:apply-templates select="From/User" />
</td>
<td />
- <td>
<xsl:apply-templates select="To/User" />
</td>
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
<td />
- <!-- From
-->
<td />
<td />
- <!-- To
-->
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="User">
- <!-- add a comma before all but the first user
-->
<xsl:if test="position() != 1">,</xsl:if>
<xsl:value-of select="@FriendlyName" />
</xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!-- zebra-stripe the sessions
-->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
<xsl:value-of select="$ZebraStripeStyle" />
</xsl:attribute>
</xsl:if>
</xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
<xsl:value-of select="@SessionID" />
</td>
<td />
</xsl:if>
- <td>
<xsl:value-of select="@Date" />
</td>
<td />
- <td>
<xsl:value-of select="@Time" />
</td>
<td />
</xsl:template>
</xsl:stylesheet>
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Xsl para transformar acentos en códigos html

Publicado por laura (1 intervención) el 01/09/2010 05:36:18
<?xml version="1.0" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <!-- localized strings
-->
<xsl:variable name="ColumnHeader_Date">Fecha</xsl:variable>
<xsl:variable name="ColumnHeader_Time">Hora</xsl:variable>
<xsl:variable name="ColumnHeader_From">De</xsl:variable>
<xsl:variable name="ColumnHeader_To">Para</xsl:variable>
<xsl:variable name="ColumnHeader_Message">Mensaje</xsl:variable>
- <!-- variables
-->
<xsl:variable name="Debug">0</xsl:variable>
<xsl:variable name="TableStyle">font-family:Segoe UI; font-size:75%; text-align:left; vertical-align:top; table-layout:fixed</xsl:variable>
<xsl:variable name="GutterStyle">width:2ex</xsl:variable>
<xsl:variable name="HeaderStyle">border-bottom:1 solid black</xsl:variable>
<xsl:variable name="UseZebraStripe">1</xsl:variable>
<xsl:variable name="ZebraStripeStyle">background-color:#e0edff</xsl:variable>
<xsl:variable name="MostRecentSessionFirst">0</xsl:variable>
- <xsl:template match="Log">
- <html dir="ltr">
- <head>
- <title>
Message Log for
<xsl:value-of select="@LogonName" />
<xsl:if test="$Debug = 1">(Debug)</xsl:if>
</title>
- <xsl:if test="$Debug = 1">
<span style="font-family:trebuchet ms; font-size:120%">Debug Version</span>
<hr />
</xsl:if>
</head>
- <body style="margin:0">
- <table id="BodyTable" style="{$TableStyle}" cellspacing="0">
- <xsl:if test="$Debug = 1">
<col style="vertical-align:top; width:5ex;" />
<col style="{$GutterStyle}" />
</xsl:if>
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:16ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:21ex;" />
<col style="{$GutterStyle}" />
<col style="width:70ex;" />
- <thead>
- <tr>
- <xsl:if test="$Debug = 1">
<th style="{$HeaderStyle}">SID</th>
<th />
</xsl:if>
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Date" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Time" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_From" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_To" />
</th>
<th />
- <th style="{$HeaderStyle}">
<xsl:value-of select="$ColumnHeader_Message" />
</th>
</tr>
</thead>
- <tbody style="vertical-align:top">
- <xsl:choose>
- <!-- newest session first
-->
- <xsl:when test="$MostRecentSessionFirst = 1">
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="descending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:when>
- <!-- oldest session first
-->
- <xsl:otherwise>
- <xsl:apply-templates>
<xsl:sort select="@SessionID" order="ascending" data-type="number" />
<xsl:sort select="@DateTime" order="ascending" />
</xsl:apply-templates>
</xsl:otherwise>
</xsl:choose>
</tbody>
</table>
</body>
</html>
</xsl:template>
- <xsl:template match="Message">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
- <td>
<xsl:apply-templates select="From/User" />
</td>
<td />
- <td>
<xsl:apply-templates select="To/User" />
</td>
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="Invitation|InvitationResponse|Join|Leave">
- <tr>
<xsl:call-template name="CommonMessageProcessing" />
<td />
- <!-- From
-->
<td />
<td />
- <!-- To
-->
<td />
- <td>
- <span>
- <xsl:attribute name="style">
<xsl:value-of select="Text/@Style" />
</xsl:attribute>
<xsl:value-of select="Text" />
</span>
</td>
</tr>
</xsl:template>
- <xsl:template match="User">
- <!-- add a comma before all but the first user
-->
<xsl:if test="position() != 1">,</xsl:if>
<xsl:value-of select="@FriendlyName" />
</xsl:template>
- <xsl:template name="CommonMessageProcessing">
- <!-- zebra-stripe the sessions
-->
- <xsl:if test="$UseZebraStripe = 1">
- <xsl:if test="(@SessionID mod 2) = 1">
- <xsl:attribute name="style">
<xsl:value-of select="$ZebraStripeStyle" />
</xsl:attribute>
</xsl:if>
</xsl:if>
- <xsl:if test="$Debug = 1">
- <td>
<xsl:value-of select="@SessionID" />
</td>
<td />
</xsl:if>
- <td>
<xsl:value-of select="@Date" />
</td>
<td />
- <td>
<xsl:value-of select="@Time" />
</td>
<td />
</xsl:template>
</xsl:stylesheet>
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar