function dp_ImageViewer(strUrl, intWidth, intHeight)
  	{  
	window.open(strUrl, 'ImagesView', 'width=' + intWidth + ',height=' + intHeight + ',scrollbars=no,resizable=no,status=no');
	}
	
function getWindowHeight() {
	var windowHeight = 0;
	if (typeof(window.innerHeight) == 'number') {
		windowHeight = window.innerHeight;
	}
	else {
		if (document.documentElement && document.documentElement.clientHeight) {
			windowHeight = document.documentElement.clientHeight;
		}
		else {
			if (document.body && document.body.clientHeight) {
				windowHeight = document.body.clientHeight;
			}
		}
	}
	return windowHeight;
}
		
function setFooter() {
	if (document.getElementById) {
		var windowHeight = getWindowHeight();
		if (windowHeight > 0) {
			var footerElement = document.getElementById('footer');
			var contentHeight = document.getElementById('main_body').offsetHeight;

			var leftHeight = document.getElementById('nav_container').offsetHeight + 200;

			var headerHeight = document.getElementById('header').offsetHeight;

			var footerHeight  = footerElement.offsetHeight;

			var totalHeight = Math.max(leftHeight,contentHeight);
			totalHeight = totalHeight + headerHeight;

			if (windowHeight - totalHeight < 0) {
				footerElement.style.position = 'absolute';
				footerElement.style.top = (totalHeight + 100) + 'px';
			}
			else {
				footerElement.style.position = 'absolute';
				footerElement.style.top = 800 + 'px';
			}
		}
	}
}