user3082812
user3082812

Reputation: 31

How to show Rss on my page

I have created xml file using the code below(aspx.cs) and now i am trying to show the xml file on my page using xslt and literal control (look in my aspx)

<xsl:for-each select="rss/channel">
  <h2>
    <a href="{link}">
      <xsl:value-of select="title" />        
    </a>

  </h2>
  <h4>
    <xsl:value-of select="description"/>
  </h4>
</xsl:for-each>

<ul>
  <xsl:for-each select="rss/channel/item">
    <li>
      <a href="{link}">
        <strong>
          <xsl:value-of select="title" />

        </strong>
      </a>

    </li>

    <xsl:value-of select="descreption"/>
    <br/>
    <xsl:value-of select="pubDate"/>

  </xsl:for-each>
</ul>

What am i doing wrong?

Upvotes: 0

Views: 209

Answers (1)

Victor
Victor

Reputation: 628

I think the error in misunderstanding of Response.End() call which "sends all currently buffered output to the client, stops execution of the page, and raises the EndRequest event."

Msdn link to Respons.End description

You should remove that line from your code snippet

Upvotes: 0

Related Questions