Guest_imported
New member
- Jan 1, 1970
- 0
Hi there,
I have a problem with more than one tag in XML. For exmplae my XML-file would be:
<site>
<text place="center">Hello!</text>
</site>
My XSL-file transform it into <p align="center">Hello!</p>
But when I have this:
<site>
<text place="center">Hello!</text>
<text place="right">My name is Sander</text>
</site>
In this case the XSL-file will transform this into:
<p align="center">Hello!</p>
<p align="right">Hello!</p>
Notice that the value of the text-tag will be shown twice. And also that this doesn't happen with the attribute "place". I tried lots of things with XSL, like:
<xsl:for-each select="site">
<xsl:value-of select="text"/>
</xsl:for-each>
But this doesn't work and now I'm out of ideas. Is there anyone to solve this difficult problem? I'll thank you for reading this problem and I hope you will answer it!!
Thnx in advance,
Sander K
I have a problem with more than one tag in XML. For exmplae my XML-file would be:
<site>
<text place="center">Hello!</text>
</site>
My XSL-file transform it into <p align="center">Hello!</p>
But when I have this:
<site>
<text place="center">Hello!</text>
<text place="right">My name is Sander</text>
</site>
In this case the XSL-file will transform this into:
<p align="center">Hello!</p>
<p align="right">Hello!</p>
Notice that the value of the text-tag will be shown twice. And also that this doesn't happen with the attribute "place". I tried lots of things with XSL, like:
<xsl:for-each select="site">
<xsl:value-of select="text"/>
</xsl:for-each>
But this doesn't work and now I'm out of ideas. Is there anyone to solve this difficult problem? I'll thank you for reading this problem and I hope you will answer it!!
Thnx in advance,
Sander K