$(document).ready(function(){
	$("#content a").bind("click", function(){
		return !window.open(this.href);
	});

	var height = $('body').height();
	var wrapperHeight = $('#wrapper').height();
	
	if(wrapperHeight < height){
		$('#wrapper').css({background: '#000', width: '400px'});

		if($.browser.msie){
			$(function(){
				$('body').css({background: 'none', filter: "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='images/content_repeat.png', sizingMethod='scale')"});
			})
		;}
		else{
			$('body').css({background: "url('http://displayinline.com/images/content_repeat.png') top center repeat-y"});
		}
	};
	
	// $('input')[0].focus();
	// var mail = $("#mail").attr('action') + '?ajax=true';
	// 
	// $('#mail').submit(function(){
	// 	var options = {
	// 		url: mail,
	// 		before: function(){
	// 			var statusHeight = $('#status').height();
	// 			var statusHeight = statusHeight + 2;
	// 
	// 			$('#status').height(statusHeight);
	// 			$('#status p').fadeOut('slow');
	// 		},
	// 		after: function(data){
	// 			$('#status p').html(data).fadeIn('slow');
	// 			$('#status').height('auto');
	// 			
	// 			if(data == 'A name is required.'){
	// 				$('#name').focus();
	// 			}
	// 			if(data == 'A phone number is required.'){
	// 				$('#phone').focus();
	// 			}
	// 			if(data == 'An email is required.'){
	// 				$('#email').focus();
	// 			}
	// 			if(data == 'A valid email address is required.'){
	// 				$('#email').focus();
	// 			}
	// 			if(data == 'A message is required.'){
	// 				$('#message').focus();
	// 			}
	// 			if(data == 'Your message has been sent!'){
	// 				$('#status p').css('text-align', 'center').css('font-size', '1em');
	// 			}
	// 			else{
	// 				$('#status p').css('text-align', 'left').css('font-size', '.8em');
	// 			}
	// 		}
	// 	};
	// 
	// 	$(this).ajaxSubmit(options);
	// 	return false;
	// });
	
	if($.browser.msie){
		$('#nav li').hover(function() {
			$(this).css('cursor', 'default');
		}, function() {
			$(this).css('cursor', 'default');
		});
	;}
});