P
Paul Johnston
Hi
Just started playing with xml and xslt and have a problem.
I have a xml file which I want to contain a hyperlink to a resouce.
I convert the xml into html for displaying in a web browser using an
xsl file.
I have replaced the < and > in the link with < and >
Could someone give me a pointer as to getting the link to work
The value-of select simply puts the string there, it
Below is a section of the xml file (URL Modified)
<word>
<adj>
<persian>????</persian>
<english>habitable</english>
<transcription>abad</transcription>
<audio><a
href="http://www.mystuff/audio/habitable.mp3">Link</a></audio>
<page>709</page>
</adj>
</word>
And here a section of the xsl file
<table border="2">
<tr>Adjectives</tr>
<tr bgcolor="#9acd20">
<th align="left">Persian</th>
<th align="left">English</th>
<th align="left">Transliteration</th>
<th align="left">Audio</th>
<th align="left">Page</th>
</tr>
<xsl:for-each select="corpus/word/adj">
<xsl:sort select="persian"/>
<tr>
<td>
<xsl:value-of select="persian"/>
</td>
<td>
<xsl:value-of select="english"/>
</td>
<td>
<xsl:value-of select="transcription"/>
</td>
<td>
<xsl:value-of select="audio"/>
</td>
<td>
<xsl:value-of select="page"/>
</td>
</tr>
</xsl:for-each>
</table>
TIA Paul
Just started playing with xml and xslt and have a problem.
I have a xml file which I want to contain a hyperlink to a resouce.
I convert the xml into html for displaying in a web browser using an
xsl file.
I have replaced the < and > in the link with < and >
Could someone give me a pointer as to getting the link to work
The value-of select simply puts the string there, it
Below is a section of the xml file (URL Modified)
<word>
<adj>
<persian>????</persian>
<english>habitable</english>
<transcription>abad</transcription>
<audio><a
href="http://www.mystuff/audio/habitable.mp3">Link</a></audio>
<page>709</page>
</adj>
</word>
And here a section of the xsl file
<table border="2">
<tr>Adjectives</tr>
<tr bgcolor="#9acd20">
<th align="left">Persian</th>
<th align="left">English</th>
<th align="left">Transliteration</th>
<th align="left">Audio</th>
<th align="left">Page</th>
</tr>
<xsl:for-each select="corpus/word/adj">
<xsl:sort select="persian"/>
<tr>
<td>
<xsl:value-of select="persian"/>
</td>
<td>
<xsl:value-of select="english"/>
</td>
<td>
<xsl:value-of select="transcription"/>
</td>
<td>
<xsl:value-of select="audio"/>
</td>
<td>
<xsl:value-of select="page"/>
</td>
</tr>
</xsl:for-each>
</table>
TIA Paul