$(document).ready(function() {
  
  	$(".ro").hover(
		function() {
	  		this.src = this.src.replace("_off","_over");
	 	},
	 	function() {
	  		this.src = this.src.replace("_over","_off");
	 	}
	);
    
    
    function preload(arrayOfImages) {
	    $(arrayOfImages).each(function(){
	        $('<img/>')[0].src = this;
	        // Alternatively you could use:
	        // (new Image()).src = this;
	    });
	}

	// Usage:
	
	preload([
	    'images/madison-roll_over.png'
		]);
  
	$('#amsterdam-shuffle').cycle({ 
	    fx: "scrollLeft",
	    easing: 'easeout', 
	    delay: -2000 
	});
	
	$('#food').cycle({ 
	    fx: 'scrollLeft',
	   	easing: 'easeout', 
	    delay: -2000 
	});
	
	$("img").lazyload({         
	     placeholder : "images/trans.png",
	     effect : "fadeIn"
	 });
	 
	 $("#car").hover(function(){
	 	$("#car-bubble").fadeIn("fast");
	 },function(){
	 	$("#car-bubble").fadeOut("fast");
	 });
	 
	 $("#fatbaby").hover(function(){
	 	$("#fatbaby-caption").fadeIn("fast");
	 },function(){
	 	$("#fatbaby-caption").fadeOut("fast");
	 });
	 
	 $("#hooters").hover(function(){
	 	$("#hooters-bubble").fadeIn("fast");
	 },function(){
	 	$("#hooters-bubble").fadeOut("fast");
	 });
	 
	 $("#tacos").hover(function(){
	 	$("#tacos-bubble").fadeIn("fast");
	 },function(){
	 	$("#tacos-bubble").fadeOut("fast");
	 });
	 
	 $("#antwerp").hover(function(){
	 	$("#antwerp-caption").fadeIn("fast");
	 },function(){
	 	$("#antwerp-caption").fadeOut("fast");
	 });
	 
	 $("#singapore").hover(function(){
	 	$("#singapore-caption").fadeIn("fast");
	 },function(){
	 	$("#singapore-caption").fadeOut("fast");
	 });
	 
	 $("#vietnam").hover(function(){
	 	$("#vietnam-caption").fadeIn("fast");
	 },function(){
	 	$("#vietnam-caption").fadeOut("fast");
	 });
	 
	 $("#hk").hover(function(){
	 	$("#hk-caption").fadeIn("fast");
	 },function(){
	 	$("#hk-caption").fadeOut("fast");
	 });
	 
	 $("#monopoly").hover(function(){
	 	$("#monopoly-caption").fadeIn("fast");
	 },function(){
	 	$("#monopoly-caption").fadeOut("fast");
	 });
	 
	 $("#clock").hover(function(){
	 	$("#clock-bubble").fadeIn("fast");
	 },function(){
	 	$("#clock-bubble").fadeOut("fast");
	 });
	 
	 $("#mimi").hover(function(){
	 	$("#mimi-caption").fadeIn("fast");
	 },function(){
	 	$("#mimi-caption").fadeOut("fast");
	 });
	 
	 $("#paris").hover(function(){
	 	$("#paris-caption").fadeIn("fast");
	 },function(){
	 	$("#paris-caption").fadeOut("fast");
	 });
	 
	 $("#train").hover(function(){
	 	$("#train-caption").fadeIn("fast");
	 },function(){
	 	$("#train-caption").fadeOut("fast");
	 });
	 
	 $("#lyon").hover(function(){
	 	$("#lyon-caption").fadeIn("fast");
	 },function(){
	 	$("#lyon-caption").fadeOut("fast");
	 });
	 
	 $("#thespot").hover(function(){
	 	$("#thespot-caption").fadeIn("fast");
	 },function(){
	 	$("#thespot-caption").fadeOut("fast");
	 });
	 
	
});
