getTwitters('tweet', { 
  id: 'thomasmarsden', 
  count: 1, 
  enableLinks: true, 
  ignoreReplies: true, 
  clearContents: true,
  template: '<p class="twitterAll"><span class="twitterStatus">%text%</span><br /><em><span class="twitterTime"><strong>&#9997;</strong> <a href="http://twitter.com/%user_screen_name%/statuses/%id%/">%time%</a></span></em>&nbsp;</p>'
});

$(window).load(function() {
	$('.flexslider').flexslider({
				  animation: "slide",
				})
});

$(document).ready(function(){
   $(".fade").fadeTo("slow", 0.7); // This sets the opacity of the thumbs to fade down to 30% when the page loads
   $(".fade").hover(function(){
   $(this).fadeTo("slow", 1.0); // This should set the opacity to 100% on hover
   },function(){
   $(this).fadeTo("slow", 0.7); // This should set the opacity back to 30% on mouseout
	   	});
   });

$(document).ready(function(){
   $(".social").fadeTo("slow", 0.3); // This sets the opacity of the thumbs to fade down to 30% when the page loads
   $(".social").hover(function(){
   $(this).fadeTo("fast", 1.0); // This should set the opacity to 100% on hover
   },function(){
   $(this).fadeTo("fast", 0.3); // This should set the opacity back to 30% on mouseout
	   	});
   });

$(document).ready(function(){
   $(".portfoli1o").fadeTo("slow", 0.5); // This sets the opacity of the thumbs to fade down to 30% when the page loads
   $(".portfolio1").hover(function(){
   $(this).fadeTo("fast", 1.0); // This should set the opacity to 100% on hover
   },function(){
   $(this).fadeTo("fast", 0.5); // This should set the opacity back to 30% on mouseout
	   	});
   });

$(document).ready(function(){
   $(".info1").fadeTo("slow", 0.8); // This sets the opacity of the thumbs to fade down to 30% when the page loads
   $(".info1").hover(function(){
   $(this).fadeTo("slow", 1.0); // This should set the opacity to 100% on hover
   },function(){
   $(this).fadeTo("slow", 0.8); // This should set the opacity back to 30% on mouseout
	   	});
   });

$(function() {
		$('ul.hover_block li').hover(function(){
			$(this).find('img').animate({top:'182px'},{queue:false,duration:500});
		}, function(){
			$(this).find('img').animate({top:'0px'},{queue:false,duration:500});
		});
	});


var paircount = 0;

/* If you want to desaturate after page loaded - use onload event
* of image.
*/
function initImage(obj)
  {
	obj.onload = null;
	var $newthis = $(obj);
	if ($.browser.msie)
	{
	  // You need this only if desaturate png with aplha channel
	  $newthis = $newthis.desaturateImgFix();
	}
	// class for easy switch between color/gray version
	$newthis.addClass("pair_" + ++paircount);
	var $cloned = $newthis.clone();
	// reset onload event on cloned object
	$cloned.get(0).onload = null;
	// add cloned after original image, we will switch between
	// original and cloned later
	$cloned.insertAfter($newthis).addClass("color").hide();
	// desaturate original
	$newthis.desaturate();
  };

  $(function(){

	$('.xxx').data('desaturate', {'level':0.5});

	$(".switched_images").bind("mouseenter mouseleave", function(event) {
		if (event.type == 'mouseenter')
		{
		  //$(".des:not(.color)", this).fadeOut(1000);
		  $(".des.color", this).fadeIn(500);
		}
		if (event.type == 'mouseleave')
		{
		  //$(".des:not(.color)", this).fadeIn(1000);
		  $(".des.color", this).fadeOut(500);
		}
	  });
  });
