/**
 * Curse Inc.
 * Writ
 * Prototype Twitter Loader
 *
 * @author 		Alex Smith
 * @copyright	(c) 2011 Curse Inc.
 * @license		All Rights Reserved
 * @package		Writ
 * @link		http://www.curse.com/
 *
**/
function pTwitter(user, limit) {
	new Ajax.JSONRequest("http://twitter.com/status/user_timeline/"+user+".json?count="+limit,
				{
					method: 'get',
					evalJSON: 'force',
					onSuccess: function(t) {
						var posts = $("twitter_posts");
				        posts.update();

				        t.responseJSON.each(function(post) {
				            posts.update(posts.innerHTML+"<li class='post'>" + post.text + "</li>");
				        });
					}
				});
}
