/**
 * Set min-width & min-height
 */
function setMinSize(id,minW,minH) {
	var html = document.getElementsByTagName("html")[0];
	var body = document.body;
	var div = document.getElementById(id);
	var windowWidth, windowHeight;
	html.style.height = "100%";
	body.style.height = "100%";
	body.style.margin = "0";
	body.style.padding = "0";
	div.style.height = "100%";
	
	function onset() {
		if (self.innerHeight) {
			windowWidth = self.innerWidth;
			windowHeight = self.innerHeight;
		} else if (document.documentElement && document.documentElement.clientHeight){
			windowWidth = document.documentElement.clientWidth;
			windowHeight = document.documentElement.clientHeight;
		}
		
		if (windowWidth < minW){
			div.style.width = minW + "px";
		} else {
			div.style.width = "100%";
		}
		
		if (windowHeight < minH){
			div.style.height = minH + "px";
		} else {
			div.style.height = "100%";
		}
		
		if (navigator.userAgent.indexOf("MSIE") != -1) {
			html.style.overflow = "hidden";
				
			if (windowWidth < minW || windowHeight < minH){
				html.style.overflow = "scroll";
			} else {
				html.style.overflow = "hidden";
			}
		}
	}
	onset();
	window.onresize = onset;
};
