XSL construct problem
Posted: Thu Jan 15, 2004 11:51 am
Hello,
i have the following xml file layout
i am trying to list the songs and link them to windows and real audio files
the link will be dyanimcally built based on the album's image value which is the name of the folder
thus
my xsl file is
Now as is rite now the code is not finished cause i dont no how to build the link dynamically in xsl
but the syntax for the link would be
Kendall
i have the following xml file layout
Code: Select all
<album>
<albumtitle>title text<album>
<image src='pathtoimage'/>
<song number="1" play="true">song name</song>
</album>the link will be dyanimcally built based on the album's image value which is the name of the folder
thus
my xsl file is
Code: Select all
// snippet
<xsl:template match="song">
<li>
<xsl:value-of select="song"/><xsl:apply-templates/>
<xsl:if test="@PLAY='true'"><a><xsl:attribute name="href"><xsl:value-of select="image src attribute value"/><xsl:value-of select="postion()"/></xsl:attribute></a><xsl:text>WIN</xsl:text></xsl:if>
</li>
</xsl:template>but the syntax for the link would be
im not sure doe how to code this in xsl....anyone knows how or understands what im trying to acheive?html a tag, the word ' albums/',value of image src tag,the word '/track', the song number, the word '.ram or .wma',then the word that acks as the link</a>
Kendall