-
Notifications
You must be signed in to change notification settings - Fork 1
Home
Twitter Status plugin for Mephisto
======
A quick edit of Dan Webb’s (http://www.danwebb.net) lastfm plugin to give you
a nice little liquid tag for your templates to display your twitter status or
a few other timelines in your mephisto blog.
SIDENOTE :: This plugin has not been tested with 0.8 of Mephisto! It probably
doesn’t work! If you have any fixes you want to submit, go ahead and fork it and
i’ll pull the fixes in from you. My suggestion, though, would be to use my
mephisto_ajaxyxml plugin instead of this one.
Usage
====
To display your statuses, you’d want to do something like this…
{% twittertimeline user: ‘username’, type: ‘user_timeline’ as status }
{ endtwittertimeline %}
Check out http://twitter.com/help/api for more information on all the
attributes of each status. You can also use {{ twittertimeline.index }} to
reference what index number your at in the loop.
You can display a few other timelines as well. Try replacing user_timeline with
friends_timeline or friends. Currently, these are the only timelines supported
because the followers timeline needs some basic auth that I haven’t implimented
yet. Caching should work too. You can change try and change the value in
twitter.rb for @@expire_cache_every if you wish cache to auto flush quicker or
not so quick. In the future, I’m going to look into implimenting the the basic
auth stuff and maybe even a way to update your status via your blog. We’ll see.
Most of the credit for this plugin has to go to Dan Webb. Head on over to
http://www.danwebb.net to check out his blog and his work. This plugin was pretty
much just a very quick edit of his lastfm plugin (which also works great, btw).
© Steve Ehrenberg 2008, under an MIT licence. http://www.opensource.org/licenses/mit-license.php
© Dan Webb 2006, under an MIT licence. http://www.opensource.org/licenses/mit-license.php