xsl-list
[Top] [All Lists]

RE: table td width

2004-03-17 10:23:10
Hi,

How can i put the value of width of td from the value of the xml file.
I can put width=22.

Use <td width="{value}" />.

An example would be:

Your XML:
<bar>
  <label>Valor2</label>
  <value>22</value>
</bar>

My XSL:
<?xml version="1.0"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>
<xsl:output method="html" indent="yes"/>

<xsl:template match="/bar">
        <table border="1">
        <tr>
        <td width="{value}">xxx</td>
        </tr>
        </table>
</xsl:template>

</xsl:stylesheet>

The OUTPUT:
<table border="1">
<tr>
<td width="22">xxx</td>
</tr>
</table>

Cheers, Pieter 


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



<Prev in Thread] Current Thread [Next in Thread>
  • table td width, aroso
    • RE: table td width, Pieter Reint Siegers Kort <=