$('.ajaxBig').live('click', function(event){
			event.preventDefault();
			var ranNum = Math.floor(Math.random()*11);
			$(".middlePart").empty();
			$.ajax
			({	
						type: "GET",
						data: "number=" + ranNum, 
						url: this.href,
						cache: false,
						 success: function(data){   $('.middlePart').html(data).hide().fadeIn(250)  }
			})
});

irc = false;
$('.ajaxWebirc').live('click', function(event){
			event.preventDefault();
			var ranNum = Math.floor(Math.random()*11);
			$(".middlePart").empty();
			if(irc == false) {
				$.ajax
				({	
							type: "GET",
							data: "number=" + ranNum, 
							url: this.href,
							cache: false,
							 success: function(data){   $('#webirc').html(data).hide().fadeIn(250)  }
				})
				irc = true;
			}
});
function closeIrc(){
	irc.quit("Closed IRC");
	$("#webirc").fadeOut(250);
	irc = false;
	$("#webirc").delay(250).empty();
}


		
// ajaxSmall puts the return information in a class named "response" *** there is a problem though, i can't figure out how to pull specific data by a variable.
 $('.ajaxSmall').live('click',function(event){
			event.preventDefault();
			var ranNum = Math.floor(Math.random()*11);
		    $.ajax
			({	
						type: "GET",
						data: "number=" + ranNum, 
						url: this.href,
						cache: false,
						 success: function(data){   $('.response').html(data).hide().fadeIn(250)  }
			})
})


// Main ajax, this is for large links in the header
function Ajax(file)
{
	$(".middlePart").empty();
	$.get(file, function(data){
    $(".middlePart").html(data).hide().fadeIn(250);
	});
}

// This makes every single form submit to the target and give the target's response in the response div
$(".ajaxForm").live('submit', function() {
	$.ajax
	({
			type: "POST",
			data: $(this).serialize(),
			url: this.action,
			success: function(data)
			{
					$('.response').html(data).hide().fadeIn(250);
			}
	})
	return false;
});

$(document).ready(function(){
	$('.entry-content a').mouseover(function(e){ $(this).find('img.thumbnail').stop().animate({ marginTop : '-25px'  }, 100).parent('a').find('span.slide-title').stop().fadeTo("slow",1.0); }); // This eliminates the need for an initial mouseover
	$('.entry-content a').live('mouseover', function() { $(this).mouseover(function(e){
		  $(this).find('img.thumbnail').stop().animate({ marginTop : '-25px'  }, 100).parent('a').find('span.slide-title').stop().fadeTo("slow",1.0); }); });	  
	$('.entry-content a').live('mouseover', function() { $(this).mouseout(function(e){
		  $(this).find('img.thumbnail').stop().animate({ marginTop : '0' }, 100).parent('a').find('span.slide-title').stop().fadeTo("fast",0.0); }); });
});
