Re: Incomplete implementations #1: Atom in IE7

The use of the default namespace in the Atom feed means that the <feed>, <entry> etc. elements are in the Atom namespace.

In your stylesheet, you’re doing:

<xsl:for-each select="feed/entry">
  ...
</xsl:for-each>

When you select elements in XSLT, if you don’t give a prefix for the element then the processor will only look for elements in no namespace. So in this case you’re selecting <feed> elements in no namespace and their <entry> element children (in no namespace again).

You already have the Atom namespace declared in the stylesheet with the prefix atom. The solution is simply to use that prefix whenever you refer to an Atom element:

<xsl:for-each select="atom:feed/atom:entry">
  ...
</xsl:for-each>

Reply

The content of this field is kept private and will not be shown publicly.