Hello

I was curious if someone could help me with the output of a feed
aggregator Im trying to use.

Right now the feed displays the content in a series of list items with
the link to read the article attached to a href. What I would like to
happen, is take the link to the rss story, and attach it to the list
item itself using location.href.


Here is the current code for the feed aggregator:

$(function() {

    $.ajax({
        type: "GET",
        url: "http://www.msn.com/rss/alsoonmsn.aspx";,
        dataType: "xml",
        success: function(rss) {
            strRSS = "<h4>" + $("/rss/channel/title",rss).text() + "</
h4>";
            $("/rss/channel/item/title:lt(5)",rss).each(function(i) {
                strRSS += "<li><a href='";
                strRSS += $("/rss/channel/item/link:eq(" + i +
")",rss).text();
                strRSS += "'>";
                strRSS += $(this).text();
                strRSS += "</a><br />";
                strRSS += ($("/rss/channel/item/description:eq(" + i +
")",rss).text()).substring(0,200) + "...</li>";
            });
            $("#feed_me").html(strRSS);
        }
    });

});

Thanks,
Anthony

Reply via email to