javascript - Google Feed API for RSS is not showing current events -
I am trying to use Google Feed API to display three current event lists for our homepage. This is to discard some of the issues that we come up with the third-party calendar app.
However, the limit of the feed has been set to 3, the only list that comes from January 18. Is there a way to show code only current or future events?
Thanks in advance for any help.
HTML
& lt ;! DOCTYPE html & gt; & Lt; Html & gt; & Lt; Top & gt; & Lt; Script src = "// code.jquery.com/jquery-1.11.1.min.js"></script> & Lt; Meta charset = "UTF-8" & gt; & Lt; Title & gt; & Lt; / Title & gt; & Lt; Script type = "text / javascript" src = "http://www.google.com/jsapi" & gt; & Lt; / Script & gt; & Lt; / Head & gt; & Lt; Body & gt; & Lt; Div id = "feed" & gt; & Lt; / Div & gt; & Lt; / Body & gt; & Lt; / Html & gt; Javascript
google.load ("Feeds", "1"); Var Feed Container = Document. GetElementById ("Feed"); Var feedurl = "http://25livepub.collegenet.com/calendars/publishers-calendar-7.rss"; Var feeds = 3; Var rssoutput = ''; Function rssfeedsetup () {var feedpointer = new google.feeds.Feed (feedurl); Feedpointer.setNumEntries (feedlimit); Feedpointer.load (displayfeed); } Function displayfeed (result) {if (! Result.error) {var thefeeds = result.feed.entries; (Var i = 0; i & lt; thefeeds.length; i ++) for (var untrimContent = thefeeds [i] .content; var trimContent = untrimContent.split ("& lt; br & gt;", 2) ; Rssoutput + = "& lt; div & gt; & lt; a href = '" + FIFF [i] .link + "' & gt;" + The feeds [i] .title + "& lt; / a & Gt; & lt; / div & gt; "+ TrimContent; feedcontainer.innerHTML = rssoutput;}} and {feedcontainer.innerHTML =" Error loading event ";}} Window.onload = function () {rssfeedsetup (); };
Comments
Post a Comment