<?xml version="1.0" encoding="utf-8"?>
<!-- generate a table (not the whole html) from rss -->
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="xml" omit-xml-declaration="yes" indent="yes"/>
<xsl:template match="/">
<xsl:apply-templates select="//channel" />
</xsl:template>
<xsl:template match="channel">
<table border="1">
<xsl:apply-templates select="//channel/item" />
</table>
</xsl:template>
<xsl:template match="item">
<tr>
<td width="20%"><a href="{link}"><xsl:value-of select="title"/></a></td>
<td width="50%"><xsl:value-of select="pubDate"/></td>
<td width="30%"><a href="mailto:{author}"><xsl:value-of select="author"/></a></td>
</tr>
<tr>
<td colspan="3"><xsl:value-of select="description"/></td>
</tr>
</xsl:template>
</xsl:stylesheet>
# |
Change |
User |
Description |
Committed |
|
#2
|
3361 |
Jay Han |
stuff description as CDATA and use XSLT substitution to turn \n to <br/> |
|
|
#1
|
3359 |
Jay Han |
generate html table (only the table) from rss |
|
|