Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/faisalman/jquery-livetweet
A jQuery plugin to fetch tweets from Twitter
https://github.com/faisalman/jquery-livetweet
Last synced: about 1 month ago
JSON representation
A jQuery plugin to fetch tweets from Twitter
- Host: GitHub
- URL: https://github.com/faisalman/jquery-livetweet
- Owner: faisalman
- Created: 2011-04-27T18:30:04.000Z (over 13 years ago)
- Default Branch: master
- Last Pushed: 2011-07-25T05:48:42.000Z (over 13 years ago)
- Last Synced: 2024-06-24T00:21:29.759Z (5 months ago)
- Language: JavaScript
- Homepage: http://www.dailygrind.it
- Size: 101 KB
- Stars: 1
- Watchers: 3
- Forks: 7
- Open Issues: 0
-
Metadata Files:
- Readme: readme.textile
Awesome Lists containing this project
README
h1. jQuery LiveTweet documentation
h2. What it does
jQuery LiveTweet is a jquery plugin that fetches your tweets from Twitter.
h2. How to use it
$(document).ready(function() {
$('#your_element').livetweet({
'username' : 'twitter_user'
});
});h2. Options
* *username*: Your twitter username. Defaults to @jeresig@ (jQuery's creator).
* *limit*: Number of tweets returned. Defaults to @5@.
* *timeout*: Request timeout. Defaults to @2000@ (2 seconds).
* *html_before*: HTML to be rendered before tweets' loop. Defaults to @
- @.
* *html_after*: HTML to be rendered after tweets' loop. Defaults to @
* *html_tweets*: HTML pattern for tweets. Defaults to @
{date}
* *use_relative_dates*: Boolean. Uses relative dates such as @2 minutes ago@. Defaults to @true@.
* *format_date*: Date formatting function. Use it if you set relative dates to false. Defaults to a date like @Wednesday 12 March 2011@.
* *loading_text*: Text displayed on loading. Defaults to @loading...@.
* *error_text*: Text displayed on errors. Defaults to @an error has occurred!@.
h2. Example
$("#your_element").livetweet({
'username' : 'sergio_martino',
'html_before' : 'These are my tweets:
',
'html_tweets' : '{date} | {text}
',
'html_after' : '
Hello!',
'loading_text' : 'ehi wait! I\'m loading...',
});
h2. Example with custom date
$("#your_element").livetweet({
'username' : 'sergio_martino',
'html_before' : 'These are my tweets:
',
'html_tweets' : '{date} | {text}
',
'html_after' : '
Hello!',
'use_relative_dates' : false,
'format_date' : function(js_date_object) {
return my_date.getDay()+'/'+my_date.getMonth()+'/'+my_date.getFullYear();
},
'loading_text' : 'ehi wait! I\'m loading...',
'error_text' : 'oooops...'
});