Twitter Atom feed blank for one user but not another? - twitter

I've been pulling the latest tweet via search.atom in Twitter.
$feed = "http://search.twitter.com/search.atom?q=from%3A" . $username_for_feed . "&rpp=" . $limit;
The problem is lately it just started showing no content. I went and looked at different URLs and it isn't showing, only for certain usernames??
http://search.twitter.com/search.atom?q=from:kevinbacon&rpp=1
That works for me.
http://search.twitter.com/search.atom?q=from:zesty_one&rpp=1
Here, both accounts have tweets, and when I add most_recent, it makes no difference, so I can't see how date has anything to do with it.

The search atom feed only goes back 7 days. So if that user with a blank feed hasn't tweeted for 7 days it won't show anything.

There is an Atom feed at
http://twitter.com/statuses/user_timeline/$username.atom?count=200

Related

Display a chosen users tweets using twitter api in a rails app

I am trying to display a chosen users tweets in my rails app. Right now the way I have it, it is pulling up their tweets and any time they are mentioned. I just want the tweets that they post and nothing else. I will not have their log in info. This will just work for public accounts. This is the code I have so far.
client.search(user_id=#band.twitter).take(20).collect do |tweet|
the #band.twitter is where I am storing the bands twitter handle.
Any help would be much appreciated.
This seemed to have Worked for me.
client.user_timeline(#band.twitter).take(20).collect do

How to intergrate a single tweet into your website

Right now im building a simple html/css site for a friend. The homepage is a series of grid block divs that hold some content.
There are currently 3 block divs we have marked for social media posts. So for example, he wants his latest tweet to appear in one of those divs. His latest instagram post to appear in another and facebook in the last.
We can ignore facebook for the time being as I'm only focusing on the twitter/instagram for now.
I'm struggling with where to begin for this project. In the past I have only embedded twitter timelines, Instagram posts using widgets etc....nothing too complicated.
But for this project I will need separate stripped down posts, ie: just the plain text from his tweet inside the twitter div. The image from his Instagram post as the background image on the Instagram block etc...
I've spent the last few hours trying to get my head around oEmbed, and I can safely say I'm failing miserably.
I'm actually more confused now then before I started, so if any kind soul could give me a dummies guide to how I can approach this, that would be absolutely amazing.
Thank you!
You can acheive a single embedded tweet using an embedded timeline.
To get just one tweet, use the data-tweet-limit attribute on the embed tag, as detailed here:
https://dev.twitter.com/web/embedded-timelines/parameters
For example:
<a class="twitter-timeline" href="https://twitter.com/TwitterDev" data-widget-id="some_id" data-tweet-limit="1"></a>
According to twitter's documentation, that is the recommended way of getting tweets onto websites. From your description of the use case, I'd highly recommend just using Twitter's official widget.
If you really want to use Twitter's REST API and generate your page server side, I'd check out this stack overflow question as a starting point:
Setting up Twitter API, getting the last few Tweets
Hope that helps!

Foursquare KML feed shows ONLY recent posts

For years, I had been using my Foursquare KML url to populate a Google Map that I then placed on my website.
A few months ago, I noticed that the feed would not load check-ins in the feed for earlier events and instead only the recent check-ins. The result has been a near empty map that goes back only a few months rather than 4 years.
I've checked with support many times over the past 6-7 months and the response is always quite general. Nobody has actually looked at my account to see what the issue is.
And the last response was to come here and ask you all.
So that's my issue:
The Foursquare KML feed only will populate a map with recent check-ins.
I've refreshed the feed URLs on the foursuare.com/feeds page and tried with that new url
When I go into my Foursquare.com/user/history page on a desktop, all my check-ins are there and are populated on that map which uses Mapbox/OpenStreetMaps.
If anyone has any advice as to how to get this problem fixed, please let me know. And if someone knows of a work-around to instead get whatever feed Foursqure is using to populate Mapbox/OpenStreetMaps, that would work great too!
Thanks again!
Have you tried adding ?count=500 to your KML feed URL? By default it seems limited to the last 10.

What is the source: attribute of a tweet sent from a tweet button using the Twitter Search API?

I'm trying to use Twitter search to find all mentions of a word that DIDN'T come from a "tweet this" button. I'm trying to build a stream of all brand mentions, but I don't want to sift through all of the retweets coming from our blog, which uses Twitter's button.
As a first step, I tried looking searching for all of the tweets that came from my personal account, filtering by source:txt. It showed all of the tweets I texted in. Then source:web. It showed all of the tweets I entered on twitter.com.
But then I tried searching with source:twitterbutton. Nothing. Then source:tweetbutton. Nothing. Same with source:tweet button. I tried searching through all of Twitter's documentation on the Tweet button to see what the source: attribute is, but couldn't find anything.
When I go through my stream of tweets without filtering for the source, I see some that say via Tweet Button so I know they exist, but I can't seem to find the right source: operator to find them automatically.
FYI: I'm using the Twitter Search API Method.
Bonus points to whoever can tell me how to negate a source (return everything EXCEPT that source)
The source is Tweet Button. The correct way to search for it will be source:tweet_button. Searching by source is very unreliable though (especially for multiword sources). Filtering by source requires that you include a keyword so you can't search just by source.
To negate a source you add a - in front like this google -source:web.
Update: Multi-word sources are now _ (underscore) separated.
I started tweeting with the fine folks over at Tweet Deck since their application lets you look for ones that came from the Tweet Button. It turns out I was only one character away. D'oh!
Use source:tweet_button to get only tweets from Tweet Buttons. And, as Abraham mentioned, all you need is a - before the parameter for it to negate that source. Example search.
Thanks for all the assistance! Especially from #DesktopDeck!

How on earth does Google Reader parse RSS?

I'm pulling hair out, i might pull a tooth out next, thats how frustrated i am.
I have deleted (for the purpose of proving a point) ALL my RSS files in my wordpress site
http://baked-beans.tv
No matter what i edit, Google Reader reads what it wants, ie: the posts, and all it's content!
So how on earth am I supposed to edit the content which most of my RSS subscribers will view (since Google Reader is very popular)
If you look here: http://baked-beans.tv/feed/
There is NO content!
And yet if I add this URL to Google reader, it generates full posts in the feed.
Furthermore!
If I edit say... wp-includes/feed-rss2.php I can see those changes within the RSS parser of Safari, Firefox, etc, but again, Google just shows the same thing, the entire post.
This really isnt on. If you go to Google Reader, and click on "Show Details" it says "Feed URL: http://baked-beans.tv/feed/" Which is just a total lie.
I really need to control how people see posts. The posts contain hefty video and a lot of images, and it parses the post in a really unattractive way.
Thanks in advance,
Marc
I'm pretty sure Google is using a cached result because your feed is completely empty (which is invalid RSS, which is probably interpreted as an error condition, like the feed being down).
Try showing a feed that is valid, but empty. That should get Google to pick up the change sooner or later.
If you'd like to edit the contents of posts that were already crawled by Reader, you'll need to republish them with the same GUID (if using RSS) or ID (if using Atom). Reader keeps copies of posts indefinitely (so that it can show historical data for feeds), and it keys things off of the ID. If it sees a post with the same ID as one it already has, it'll update the content of its copy with the new crawled content (more details here).

Resources