Subject: RE: [xsl] show if there is more than one node From: "Kenny Akridge" <kenny@xxxxxxxxxxxxxxxxx> Date: Sat, 1 May 2004 16:05:44 -0400 |
<xsl:if test="count(/sn_paginas/pagina_id) > 1"> ... </xsl:if> -----Original Message----- From: Dionisio Ruiz de Zarate [mailto:dionisio@xxxxxxxxxxxxx] Sent: Saturday, May 01, 2004 2:27 PM To: XSL-List@xxxxxxxxxxxxxxxxxxxxxx Subject: [xsl] show if there is more than one node heloow. i have this xml: <?xml version="1.0" encoding="ISO-8859-1" standalone="yes"?> <sn_servicioproyecto> <sn_masterinformacion> <paginas> <sn_paginas> <pagina_id><![CDATA[1691]]></pagina_id> </sn_paginas> <sn_paginas> <pagina_id><![CDATA[1692]]></pagina_id> </sn_paginas> <sn_paginas> <pagina_id><![CDATA[1693]]></pagina_id> </sn_paginas> </paginas> </sn_masterinformacion> </sn_servicioproyecto> whith: <?xml version="1.0" encoding="ISO-8859-1"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:output method="html" version="1.0" encoding="ISO-8859-1" indent="yes" omit-xml-declaration="yes"/> <xsl:strip-space elements="*"/> <xsl:template match="/"> <xsl:for-each select="sn_servicioproyecto/sn_masterinformacion/paginas/sn_paginas"> <xsl:_value-of select="pagina_id"/> </xsl:for-each> i can print all the pagina id values. but i have one problem, if only there is one sn_paginas/pagina_id i dont want to print it, only i want to print them if there are more than one node. how can i make it? can you help me? thanks
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] show if there is more than on, Dionisio Ruiz de Zár | Thread | RE: [xsl] Inserting White Space (&n, Animesh Sharma |
[xsl] show if there is more than on, Dionisio Ruiz de Zár | Date | RE: [xsl] Inserting White Space (&n, Animesh Sharma |
Month |