
$(function(){
	set_class()
})


window.onresize = function(){
	set_class()

	
	
}

function set_class(){

	
	/* Add the div to hold the image
	**********************************/
	//Remove the exitsing one
	// $("#page_image").remove()
	// 	
	// 	// 1. Add a new div
	// 	$("#wrapper").prepend("<div id='page_image'></div>")
	
	// 2. Position the div left of the #inner_wrapper
	// 3. Make the width fill the rest of the screen
	// 4. Make the height fill the height of the screen
	$("#page_image").css({
		width: $(window).width() - 533,
		height: $(window).height(),
		position: "absolute",
		left: "533px"
	})
	
	w = $(window).width() 
	h = $(window).height() 
	
	if(w>h){
		$("#page_image img").css({
			height: $(window).height()
		})
	}
	else{
		$("#page_image img").css({
			width: "auto"
		})
	}
	
	
}


