Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- How to get all posts from facebook user news feed for specific day
- @feed = Koala::Facebook::API.new(current_user.token)
- to = Time.now.to_i
- yest = 1.day.ago.to_i
- @feed.fql_query("SELECT post_id, actor_id, target_id, message, likes FROM stream WHERE source_id = me() AND created_time > #{yest} AND created_time < #{to} AND type = 80
- AND strpos(attachment.href, "youtu") >= 0")
- require 'koala'
- @graph = Koala::Facebook::API.new("YOUR_ACCESS_TOKEN")
- @graph.fql_query("SELECT post_id, actor_id, target_id, message FROM stream WHERE source_id = me() AND created_time > START_TIME AND created_time < END_TIME LIMIT 10")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement