function openWindow(name,type, URL, position){
	if (!position) position = 20
	if (type == 'weblab'){
		popupWidth = 690;
		popupHeight = 440;
		if (screen.width < 700) popupWidth = 600
		if (screen.height < 500) popupHeight = 380
		
	}
	
	else if (type == 'screenshot'){
		popupWidth = 540;
		popupHeight = 440;
	}
	
	else if (type == 'drawing'){
		popupWidth = 575;
		popupHeight = 460;
	}
	
  properties = 'width=' + popupWidth + ',height=' + popupHeight +',scrollbars=yes,left=' + position + ',top=' + position + ',status=yes,resizable=yes';
  app_demo = window.open(URL,name,properties);
	window.app_demo.focus();
  return false;

}

// Note about opening windows:
// ----------------------------
// To achieve thin titlebar with only close button in Netscape only,
// add the attribute "dependent" to the window properties