0

jGFeed を使用して RSS フィードを解析しています。コードは以下のとおりです。

$.jGFeed('http://feeds.bbci.co.uk/news/rss.xml',
          function(feeds){
            // Check for errors
            if(!feeds){
              // there was an error
              return false;
            }
            // do whatever you want with feeds here
            $('#newsTimeline').empty();
            for(var i=0; i<feeds.entries.length; i++){
                var entry = feeds.entries[i];
                var title = entry.title;
                var description = entry.description;
                var linkUrl = entry.link_url;
                var date = getDate(entry.pubDate);
                var time = getTime(entry.pubDate);
                $('#newsTimeline').append('<li><time class="cbp_tmtime" datetime="'+date+' '+time+'"><span>'+date+'</span> <span>'+time+'</span></time><div class="cbp_tmicon cbp_tmicon-phone"></div><div class="cbp_tmlabel"><h2>'+title+'</h2><p>'+description+'</p></div></li>');
            }
        }, 10);

問題は、それが entry.title に対して機能していることですが、その後は何も機能しません: 最後のページ


注: Javascript コンソールにエラーは記録されません。

4

1 に答える 1

3

これを試して

       for(var i=0;i<feeds.entries.length;i++){
            var entry = feeds.entries[i];
            var title = entry.title;
            var linkUrl= entry.link;
            var description = entry.contentSnippet;
            var date = entry.publishedDate;
            $('#newsTimeline').append('<li><time class="cbp_tmtime" datetime="'+date+'       '+time+'"><span>'+date+'</span> <span>'+time+'</span></time><div class="cbp_tmicon cbp_tmicon-phone"></div><div class="cbp_tmlabel"><h2>'+title+'</h2><p>'+description+'</p></div></li>');
            }
于 2013-07-27T07:28:58.080 に答える