/***********************************************
* Function to dynamically resize div based on window height.
* Resize target div through css style and subtract a variable difference.
* Call function like resizediv('sizediv', 250) which will set the div height to the height of window - 250px
* Copyright Marian Zamfirescu. This note must be kept with all instances of the scripts wherever used.
* This script may not be re-distributed in any for-profit form.
* Modified for Kitchen Pick to adjust height based on size of footer and amount of content starting @ line 25
***********************************************/
function resizediv(divtosize, diff) {
	var wwidth = 0, wheight = 0;
	var targetdiv = document.getElementById(divtosize);
	if (typeof( window.innerWidth) == 'number') {
		//Anything but IE
		wheight = window.innerHeight;
	}
	else if (document.documentElement && (document.documentElement.clientWidth || document.documentElement.clientHeight)) {
		//IE 6+ Standards Mode
		wheight = document.documentElement.clientHeight;
	}
	else if (document.body && (document.body.clientWidth || document.body.clientHeight)) {
		//Older IE
		wheight = document.body.clientHeight;
	}
	targetdiv.style.height = "100%";
	if ((targetdiv.offsetHeight - 52) < (wheight - diff)) {
		targetdiv.style.height = wheight - diff + "px";
	}
}