On Wednesday, June 29, 2011 6:56:52 PM UTC+1, jcorso wrote:
> I am using a the Twitter widget in 'profile' mode to display news and 
> events on my website.  (Twitter user is @ProfJasonCorso and the url is 
> http://www.cse.buffalo.edu/~jcorso)  However, I would like to filter 
> the tweets that are displayed in the widget to only those containing 
> the hashtags #news or #events.  I cannot figure out how to use the 
> 'filters' feature of the widget (even after reading the widget.js with 
> my somewhat outdated knowledge of javascript) and cannot find any 
> documentation or examples about it.  Nor can I find another way of 
> doing it. 
The basic "test it out" pages at http://twitter.com/about/resources/widgets 
are handy for trying out various features, and will then show the code you 
And I take it you've got the documented un-minified source of the widget 
code from 


to look at .

> Note, I think the 'profile' mode is appropriate rather than the 
> 'search' mode because I believe Twitter only indexes recent tweets for 
> search and I need all of them to appear. 

The setUser() call seems to call setSearch(" "), so if you want to 
experiment combining them, I'd do something like

but personally, I use the REST API to pull in the tweets and then filter 
them as I want, and then poke beneath the covers of the widget to give it a 
list of tweets to display (rather than letting it fetch them itself).

So if you want to look at that as an option, the way you can do it with the 
current widget code is to call


instead of start()


Twitter developer documentation and resources: https://dev.twitter.com/doc
API updates via Twitter: https://twitter.com/twitterapi
Issues/Enhancements Tracker: https://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 

Reply via email to