The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

Old Ego-one rss feed script

View previous topic View next topic Go down

Old Ego-one rss feed script

Post by Mr-_-Insano on December 19th 2010, 8:11 pm

I would like to try to get a feed on my forum like
http://world-dezign.forumotion.com/forum
i think this requires the old ego-one script, but i need a little help getting things set up..any ideas??
Code:
 <script type="text/javascript">



        google.load("feeds", "1");



        function initialize() {

          var feed = new google.feeds.Feed("http://www.digg.com/rss/index.xml");

          feed.load(function(result) {

            if (!result.error) {

              var container = document.getElementById("feed");

              for (var i = 0; i < result.feed.entries.length; i++) {

                var entry = result.feed.entries[i];

                var div = document.createElement("div");

                div.appendChild(document.createTextNode(entry.title));

                container.appendChild(div);

              }

            }

          });

        }

        google.setOnLoadCallback(initialize);



        </script>



    <script type="text/javascript" src="http://googleajaxfeed3_files/rssdisplayer.js"></script>

    <script>

    google.load("feeds", "1") //Load Google Ajax Feed API (version 1)



    function rssdisplayer(divid, url, feedlimit, showoptions){

    this.showoptions=showoptions || "" //get string of options to show ("date" and/or "description")

    var feedpointer=new google.feeds.Feed(url) //create new instance of Google Ajax Feed API

    feedpointer.setNumEntries(feedlimit) //set number of items to display

    document.write('<div id="'+divid+'" style="display:none;">Loading feed...</div>')

    this.feedcontainer=document.getElementById(divid)

    var displayer=this

    feedpointer.load(function(r){displayer.formatoutput(r)}) //call Feed.load() to retrieve and output RSS feed

    }





    rssdisplayer.prototype.formatdate=function(datestr){

    var itemdate=new Date(datestr)

    return "<span style='color:#ececec; font-size: 70%'>"+itemdate.toLocaleString()+"</span>"

    }


    rssdisplayer.prototype.formatoutput=function(result){

    if (!result.error){ //if RSS feed successfully fetched

    var thefeeds=result.feed.entries //get all feed entries as a JSON array

    var rssoutput="<ul>"

    for (var i=0; i<thefeeds.length; i++){ //loop through entries

    var itemtitle=" » <a href="" + thefeeds[i].link + "" target="_blank">" + thefeeds[i].title + "</a>"

    var itemdate=/date/i.test(this.showoptions)?"
"+this.formatdate(thefeeds[i].publishedDate) : ""

    var itemdescription=/description/i.test(this.showoptions)? "
"+thefeeds[i].content : /snippet/i.test(this.showoptions)? "
"+thefeeds[i].contentSnippet  : ""

    rssoutput+="<li>" + itemtitle + " " + itemdate + itemdescription + "</li>"

    }

    rssoutput+="</ul>"

    this.feedcontainer.innerHTML=rssoutput

    }

    else //else, output error

    alert("Error fetching feeds: "+result.error.message)

    }




    //new rssdisplayer("adiv", "http://www.cssdrive.com/index.php/news/rss_2.0/", 5, "date, description")</script>

i also found this script in the topic at ego-one
http://www.ego-one.com/viewtopic.php?f=25&t=74
Code:
function parse_date(datee){
var current_ = (Date()).match(/(...)\s(...)\s(.{0,2})\s(.{0,4})\s(.{0,2})\:(.{0,2})\:(.{0,2})\s(.{0,3})([\+\-])(.{0,4})/i);
var target_ = (datee).match(/(...)\s(...)\s(.{0,2})\s(.{0,4})\s(.{0,2})\:(.{0,2})\:(.{0,2})\s(.{0,3})([\+\-])(.{0,4})/i);
current_[3] = Number(current_[3]);if(current_[3]==target_[3] && current_[2]==target_[2]){
return("Today at "+target_[5]+":"+target_[6]);
} else if((current_[3]-1)==target_[3] && current_[2]==target_[2]){
return("Yesterday at "+target_[5]+":"+target_[6]);
} else {
return(target_[2]+" "+target_[3]+" "+target_[4]+" at "+target_[5]+":"+target_[6]);
}
return null;
}

Mr-_-Insano
New Member

Posts : 17
Reputation : 0
Language : Englilsh

Back to top Go down

Re: Old Ego-one rss feed script

Post by Mr-_-Insano on December 19th 2010, 8:37 pm

*Bump*

Mr-_-Insano
New Member

Posts : 17
Reputation : 0
Language : Englilsh

Back to top Go down

ny skyride

Post by redskiller24 on December 20th 2010, 1:20 am

Spam Removed

redskiller24
New Member

Posts : 1
Reputation : 0
Language : english

Back to top Go down

Re: Old Ego-one rss feed script

Post by Mr-_-Insano on December 21st 2010, 11:54 pm

*bump*

Mr-_-Insano
New Member

Posts : 17
Reputation : 0
Language : Englilsh

Back to top Go down

Re: Old Ego-one rss feed script

Post by Mr-_-Insano on December 22nd 2010, 3:29 am

*bump*
help me get this up for the holidays Smile thanx in advance

Mr-_-Insano
New Member

Posts : 17
Reputation : 0
Language : Englilsh

Back to top Go down

Re: Old Ego-one rss feed script

Post by Mr-_-Insano on December 23rd 2010, 1:01 am

*Bump*

Mr-_-Insano
New Member

Posts : 17
Reputation : 0
Language : Englilsh

Back to top Go down

Re: Old Ego-one rss feed script

Post by Mr-_-Insano on December 24th 2010, 4:18 am

*bump*

Mr-_-Insano
New Member

Posts : 17
Reputation : 0
Language : Englilsh

Back to top Go down

Re: Old Ego-one rss feed script

Post by Anime Creator on December 24th 2010, 6:32 am

I also need this please someone help

Anime Creator
Forumember

Posts : 337
Reputation : 7
Language : english

http://www.narutoland.net/index.htm

Back to top Go down

Re: Old Ego-one rss feed script

Post by Mr-_-Insano on December 24th 2010, 5:12 pm

*bump*

Mr-_-Insano
New Member

Posts : 17
Reputation : 0
Language : Englilsh

Back to top Go down

Re: Old Ego-one rss feed script

Post by Yakko! on January 24th 2011, 5:00 pm

i need it too!

Yakko!
Forumember

Male Posts : 661
Reputation : -5
Language : Italian, english, Français

Back to top Go down

Re: Old Ego-one rss feed script

Post by Guest on January 24th 2011, 8:40 pm

Code:

<script type="text/javascript" src="http://www.google.com/jsapi?key=ABQIAAAA7eIzy-nhw15oRi1VFsPIaBQLfwdOeVqlPYn2aeR7PenOUsSEWxRHyJa-h_PHhev828-oDCX0Sqjv1Q"></script>

    <script type="text/javascript">

 

    google.load("feeds", "1");

 

    function initialize() {

      var feed = new google.feeds.Feed("http://www.digg.com/rss/index.xml");

      feed.load(function(result) {

        if (!result.error) {

          var container = document.getElementById("feed");

          for (var i = 0; i < result.feed.entries.length; i++) {

            var entry = result.feed.entries[i];

            var div = document.createElement("div");

            div.appendChild(document.createTextNode(entry.title));

            container.appendChild(div);

          }

        }

      });

    }

    google.setOnLoadCallback(initialize);

 

    </script>



<script type="text/javascript" src="http://googleajaxfeed3_files/rssdisplayer.js"></script>

<script>

google.load("feeds", "1") //Load Google Ajax Feed API (version 1)



function rssdisplayer(divid, url, feedlimit, showoptions){

this.showoptions=showoptions || "" //get string of options to show ("date" and/or "description")

var feedpointer=new google.feeds.Feed(url) //create new instance of Google Ajax Feed API

feedpointer.setNumEntries(feedlimit) //set number of items to display

document.write('<div id="'+divid+'" style="display:none;">Loading feed...</div>')

this.feedcontainer=document.getElementById(divid)

var displayer=this

feedpointer.load(function(r){displayer.formatoutput(r)}) //call Feed.load() to retrieve and output RSS feed

}





rssdisplayer.prototype.formatdate=function(datestr){

var itemdate=new Date(datestr)

return "<span style='color:#ececec; font-size: 70%'>"+itemdate.toLocaleString()+"</span>"

}


rssdisplayer.prototype.formatoutput=function(result){

if (!result.error){ //if RSS feed successfully fetched

var thefeeds=result.feed.entries //get all feed entries as a JSON array

var rssoutput="<ul>"

for (var i=0; i<thefeeds.length; i++){ //loop through entries

var itemtitle="<a href="" + thefeeds[i].link + "" target="_blank">" + thefeeds[i].title + "</a>"

var itemdate=/date/i.test(this.showoptions)?"<br />"+this.formatdate(thefeeds[i].publishedDate) : ""

var itemdescription=/description/i.test(this.showoptions)? "<br />"+thefeeds[i].content : /snippet/i.test(this.showoptions)? "<br />"+thefeeds[i].contentSnippet  : ""

rssoutput+="<li>" + itemtitle + " " + itemdate + itemdescription + "</li>"

}

rssoutput+="</ul>"

this.feedcontainer.innerHTML=rssoutput

}

else //else, output error

alert("Error fetching feeds: "+result.error.message)

}




//new rssdisplayer("adiv", "http://www.cssdrive.com/index.php/news/rss_2.0/", 5, "date, description")</script>

<style type="text/css">
#cssdrive li{
list-style: none;
padding: 3px;
}
</style>

</head>



<body>
<div id="cssdrive">   
<p>
<script type="text/javascript">
new rssdisplayer("cssdrive", "http://FORUM NAME HERE.com/feed/", 20, "date")
</script></p></div>

</body>

</html>

Guest
Guest


Back to top Go down

Re: Old Ego-one rss feed script

Post by Yakko! on January 25th 2011, 3:52 pm

i'll try it!

Yakko!
Forumember

Male Posts : 661
Reputation : -5
Language : Italian, english, Français

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum