Hey All,
I wrote my own twitter feed class for a website I'm working on. It takes a collection of tweets from 8 different stores and posts them on pages of each store. The idea was to see what was going on in all stores even when you are only looking at a single
store. Clear as mud? :-)
Since twitter has limitations on how many times you can pull data from them I cached the twitter results for 15 minutes and on each page load event I check if it's been 15 minutes, if it has the cache is reset and the "storeTweet" is executed again.
Here is my code.
Response.Cache.SetExpires(DateTime.Now.AddMinutes(15))
Response.Cache.SetCacheability(HttpCacheability.Server)
Dim ds As New DataSet
Dim i As Integer
Dim str As New StringBuilder
Dim Source As String
Source = Cache("storeTweets")
If Source Is Nothing Then
ds.Tables.Ad ...
Go to the complete details ...