$(document).ready(function() {
	
	var _recent = {
		username: 'leonbarrett',
	 	placeholder: 'recent',
	 	defaultthumb: 'images/blank_insert.gif',
	 	period: '7day',
	 	count: 4,
	 	refresh: 1,
	 	offset: 0
	};
	
	lastFmRecords.init(_recent);
	
	$("#twitter").getTwitter({
		userName: "leonbarrett",
		numTweets: 1,
		loaderText: "Loading tweets...",
		slideIn: false,
		showHeading: true,
		headingText: "Latest from Twitter",
		showProfileLink: false
	});
					
	$.getFeed({
		url: 'http://www.leonbarrett.com/proxy.php?url=http://feeds.foursquare.com/history/H0UQKLS50X3F4V5O5UATDJOBR253LGJP.rss',
	    success: function(feed) {	                    
		    var html = '<ul>';
		            
	        for(var i = 0; i < feed.items.length && i < 5; i++) {
	        
	            var item = feed.items[i];
	            
	            html += '<li>'
	            + '<a href="'
	            + item.link
	            + '">'
	            + item.title
	            + '</a> - '
	            + jQuery.timeago(item.updated);
	            + '</li>';
	            
	        }
		            
		    html += '</ul>';
		            
		    $('#foursquare').append(html);
	    }    
	});


	$('#social_links li').mouseover(function(){
		$(this).fadeTo("slow",0.4)
		}).mouseout(function(){
		$(this).fadeTo("fast",1)
	})
		
});