This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Twit.get( | |
| 'search/tweets', | |
| { | |
| q: 'banana since:2013-12-11', | |
| count: 10 | |
| }, | |
| function(err, reply) { | |
| for (var obj in reply['statuses']) { | |
| console.log(reply['statuses'][obj].text); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Feeds = new Meteor.Collection('feeds'); | |
| if (Meteor.isServer) { | |
| Meteor.methods({ | |
| twit_get: function() { | |
| Twit = new TwitMaker({ | |
| consumer_key: 'foo', | |
| consumer_secret: 'foo', | |
| access_token: 'foo', | |
| access_token_secret: 'foo' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Feeds = new Meteor.Collection('feeds'); | |
| if (Meteor.isServer) { | |
| var twitter_user_id = 0; | |
| Meteor.methods({ | |
| twit_get: function() { | |
| Twit = new TwitMaker({ | |
| consumer_key: 'foo', | |
| consumer_secret: 'foo', | |
| access_token: 'foo', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Feeds = new Meteor.Collection('feeds'); | |
| if (Meteor.isServer) { | |
| var twitter_user_id = 0; | |
| var boundCallback = Meteor.bindEnvironment(function (err, resp) { | |
| var timestamp = new Date().getTime(); | |
| for (var obj in resp['statuses']) { | |
| twitter_user_id = resp['statuses'][obj].user.id; | |
| Feeds.insert({ | |
| feed: resp['statuses'][obj].text, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Feeds = new Meteor.Collection('feeds'); | |
| if (Meteor.isServer) { | |
| var twitter_user_id = 0; | |
| var boundCallback = Meteor.bindEnvironment(function (err, resp) { | |
| var timestamp = new Date().getTime(); | |
| if (err !== null) { | |
| console.log(err); | |
| return; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| I20131222-11:18:52.478(-7)? { _mongo: | |
| I20131222-11:18:52.478(-7)? { _connectCallbacks: [ [Function], [Function] ], | |
| I20131222-11:18:52.479(-7)? _observeMultiplexers: | |
| I20131222-11:18:52.479(-7)? { '{"ordered":false,"collectionName":"users","selector":{},"options":{"transform":null,"fields":{"services.resume":1}}}': [Object], | |
| I20131222-11:18:52.479(-7)? '{"ordered":false,"collectionName":"feeds","selector":{},"options":{"transform":null}}': [Object], | |
| I20131222-11:18:52.479(-7)? '{"ordered":false,"collectionName":"meteor_accounts_loginServiceConfiguration","selector":{},"options":{"transform":null,"fields":{"secret":0}}}': [Object], | |
| I20131222-11:18:52.480(-7)? '{"ordered":false,"collectionName":"users","selector":{},"options":{"transform":null,"fields":{"profile":1,"username":1,"services.twitter.profile_image_url":1,"services.twitter.profile_image_url_https":1,"services.twitter.lang":1,"services.twitter.id":1,"services.twitter.screenName":1}}}': [Object] }, | |
| I20131222-11:18: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Feeds = new Meteor.Collection('feeds'); | |
| if (Meteor.isClient) { | |
| Meteor.setInterval(function () { | |
| var sound = new Audio('static/media/ahem.wav'); | |
| sound.play(); | |
| }, 5000); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var sound = new Audio('static/media/ahem.wav'); | |
| sound.play(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Feeds = new Meteor.Collection('feeds'); | |
| if (Meteor.isServer) { | |
| var twitter_user_id = 0; | |
| var boundCallback = Meteor.bindEnvironment(function (err, resp) { | |
| var play = true; | |
| return play; | |
| }); | |
| Meteor.methods({ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if (Meteor.isClient) { | |
| Template.twitter_feeds.feeds = function () { | |
| return Feeds.find({}, {sort: {created_at: -1}}); | |
| }; | |
| Meteor.setInterval(function () { | |
| Meteor.call('twit_get'); | |
| var count = Feeds.find({}).count(); | |
| var play = false; | |
| console.log(count); | |
| while (count > 7) { |
OlderNewer