// JavaScript Document

function printbox($url) {
	var height=screen.height /2;
	var width=screen.width /2;
	var left = (screen.width - width) /2;
	var top = (screen.height - height) /2;
	popUpWindow($url, left, top, width, height)



}

function knowledgebase_open() {
	
	var height =	screen.height /2;
	var width =	screen.width /2;
	
	var left =	(screen.width - width) /2;
	var top =	(screen.height - height) /2;
	popUpWindow('/index.php?action=knowledgebase', left, top, width, height)



}

// Dummy console declaration.
if (typeof (console) == 'undefined' || console == null) {

	console = {
	    log: function () {
		return;
	    },
	    
	    show: function () {
		return;
	    },
	    
	    hide: function () {
		return;
	    }
	}

	//alert ('console does not exist');
}

function session_alert () {

	alert("iAssist SAM\n--------------------\nYour browser session is about to expire\nPlease submit any unsaved data to prevent loss.\n--------------------");

}


var popUpWin=0;

function popUpWindow(URLStr, left, top, width, height)
{
  if(popUpWin)
  {
    if(!popUpWin.closed) popUpWin.close();
  }
  popUpWin = open(URLStr, 'popUpWin', 'toolbar=yes,location=yes,directories=no,status=no,menubar=yes,scrollbars=yes,resizable=yes,copyhistory=yes,width='+width+',height='+height+',left='+left+', top='+top+',screenX='+left+',screenY='+top+'');
}

