Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Hi I want to read this xml using xslt but for some reason I can't access the tags. this is my code:
<xsl:template match="/"> <!-- start writing XSLT --> <xsl:variable name="dateString" select="concat('http://www.hebcal.com/converter/','?cfg=xml&gy=2013&gm=8&gd=11&g2h=1')" /> <xsl:variable name="MyFeed" select="umbraco.library:GetXmlDocumentByUrl($dateString)" /> <!--<xsl:variable name="MyFeed" select="umbraco.library:GetXmlDocumentByUrl('http://newsrss.bbc.co.uk/rss/sportonline_uk_edition/front_page/rss.xml')" />--> <span> <xsl:value-of select="$MyFeed"/> </span> <span> <xsl:value-of select="$dateString"/> </span> <ul class="hebrewDate"> <xsl:for-each select="$MyFeed"> <li><xsl:value-of select="hebrew" /></li> </xsl:for-each> </ul> </xsl:template> </xsl:stylesheet>
the part of $dateString is working fine and I am getting the right URL, but I want to get the str value inside the hebrew tag.
this is the XML example
<hebcal> <gregorian year="2013" month="8" day="11"/> <hebrew year="5773" month="Elul" day="5" str="ה׳ בְּאֱלוּל תשע״ג"/> </hebcal>
Hi Moran,
Your $MyFeed variable contains the XML document, so you need to use an XPath to extract the data, e.g.:
<ul class="hebrewDate"> <li><xsl:value-of select="$MyFeed/hebcal/hebrew/@str" /></li> </ul>
/Chriztian
Thanks :) working great
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.
Continue discussion
Reading xml tags from url
Hi I want to read this xml using xslt but for some reason I can't access the tags. this is my code:
the part of $dateString is working fine and I am getting the right URL, but I want to get the str value inside the hebrew tag.
this is the XML example
Hi Moran,
Your $MyFeed variable contains the XML document, so you need to use an XPath to extract the data, e.g.:
/Chriztian
Thanks :) working great
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.