BRAHMA wrote:

> Hi All,
>
>         Again a question...!!
>  ---------------------------------------------------
>            <?xml version="1.0"?>
>            <root>
>            <money>
>            <net_amount>50000</net_amount>
>            <vatrate>16%</vatrate>
>             <vat>8000</vat>
>            <total_amount>58000</total_amount>
>            <currency_symbol>DM</currency_symbol>
>            <ratio>100</ratio>
>            </money>
>            </root>
> ------------------------------------------------------
> So I want to format the money value..I can use the format function....
>
> But how can I dynamically select money value from xml file and pass to
> the format function of  xsl?
> ------------------------------------------------
> <xsl:decimal-format name="eurofrmt"
> decimal-separator="," grouping-separator="."/>
>
> <xsl:template match="/">
> <xsl:value-of
> select="format-number($net_amount, '#.###,00', 'eurofrmt')"/>
> </xsl:template>
>

You should try

<xsl:template match="/">
<xsl:value-of select="format-number(root/money/net_amount, '#.###,00',
'eurofrmt')"/>
</xsl:template>

This is basic xsl/xpath stuff.

thierry


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

Reply via email to