savannah-hackers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Savannah-hackers] RSS for GNU?


From: Nic Ferrier
Subject: [Savannah-hackers] RSS for GNU?
Date: 22 Apr 2003 23:27:24 +0100

Has anyone considered an RSS feed for www.gnu.org? Maybe to announce
new software releases?

Here is some XSL that could generate an RSS feed from the new
releases page.

  <?xml version="1.0"?>
  <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"; 
version="1.0">

  <xsl:output method="xml"/>

  <xsl:template match="/">
          <entryset>
                  <xsl:apply-templates select="//dl"/>
          </entryset>
  </xsl:template>

  <xsl:template match="dl">
     <xsl:for-each select="dd/ul/li">
          <entry>
                  <title><xsl:value-of select="a/strong"/></title>
                  <link><xsl:value-of select="a/@href"/></link>
                  <date><xsl:value-of 
select="../../preceding-sibling::dt[1]"/></date>
          </entry>
     </xsl:for-each>
  </xsl:template>

  </xsl:stylesheet>


You can run it with gnome's xsltproc like this:

    xsltproc --html t.xsl http://www.gnu.org/server/new-software.html

I'd be happy to turn this into RSS if anyone is interested.



Nic





reply via email to

[Prev in Thread] Current Thread [Next in Thread]