This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Re: Converting RSS to HTML
- To: xsl-list at lists dot mulberrytech dot com
- Subject: Re: [xsl] Converting RSS to HTML
- From: Eric van der Vlist <vdv at dyomedea dot com>
- Date: Tue, 20 Feb 2001 17:48:09 +0100
- Organization: Dyomedea <http://dyomedea.com>
- References: <83E74AD370F0D311BAE900B0D02169682650FF@MOBILEAWARE01>
- Reply-To: xsl-list at lists dot mulberrytech dot com
Ronan Brady wrote:
>
> I'm trying to convert from RSS 1.0 to HTML, but I'm having serious trouble
> selecting elements from the RSS file.
> Specifically, the element <rdf:RDF> is causing me problems because it's
> qualified by a namespace.
The other elements are also qualified, even if you are using a default
namespace.
What you need is to add a declaration for the RSS namespace in you
stylesheet:
<xsl:stylesheet
version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:rss="http://purl.org/rss/1.0/"
>
and the qualify all your elements
(for instance: select="/rdf:RDF/rss:channel").
Hope this helps.
Eric
--
See you in Austin (Knowledge Technologies 2001)
http://www.gca.org/attend/2001_conferences/kt_2001/mon.htm
------------------------------------------------------------------------
Eric van der Vlist Dyomedea http://dyomedea.com
http://xmlfr.org http://4xt.org http://ducotede.com
------------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list