// JavaScript Document

//msgBox('200', '100', "Some Text");


function welcomeBox() {
	
	var width = '500';
	var height = '250';
	
	oDivH = window.document.createElement("div");
	oDivH.setAttribute('id', 'divMsgBox');
	oDivH.style.position = "absolute";
	oDivH.style.top = "50%";
	oDivH.style.left = "0px";
	oDivH.style.height =  "1px";
	oDivH.style.width = "100%";
	oDivH.style.overflow = "visible";
	oDivH.style.zIndex = 999;
	//oDivH.style.backgroundImage = "images/transptile.gif";
	oDivH.style.backgroundColor = "transparent";
	width = width.replace('px', '');
	height = height.replace('px', '');
	var sWidth = width + 'px';
	var leftMargin = ((width / 2) * -1) + 'px';	
	var sHeight = height + 'px';
	var topMargin = ((height / 2) * -1) 
	topMargin = (topMargin - 40) + 'px';	
	
	oDivC = window.document.createElement("div");
	oDivC.style.width = sWidth;
	oDivC.style.marginLeft = leftMargin;
	oDivC.style.height = sHeight;
	oDivC.style.top = topMargin;
	oDivC.style.left = "50%";
	oDivC.style.position = "absolute";
	oDivC.style.visibility = "visible";
	oDivC.style.backgroundColor = "white";
	//oDivC.style.backgroundImage = "images/tiles/blue023.jpg";
	oDivC.style.filter = "alpha(opacity = 95)";
	oDivC.style.opacity =".95";
	
	var msgText = '<p><b>Thank you for visiting ITScope!</b></p>'+
'<p>We provide essential metrics, specifications and event notifications that help you manage your IT environment.</p>'+
'<p>Please take some time to discover the many unique and exciting features this site has to offer.</p>'+
'<p>You will be surprised about how helpful ITScope can be for you!</p>'+
'<p>&nbsp;</p>'+
'<p>(Click to continue.)</p>'
	
	oDivC.style.backgroundRepeat = "repeat";
	oDivC.style.padding = "60px";
	oDivC.style.fontFamily = "Verdana, Geneva, Arial, sans-serif";
	oDivC.style.fontSize = "small";
	oDivC.style.color = "black";
	oDivC.setAttribute("onclick", "dismissLayer('divMsgBox')");
	oDivC.innerHTML = msgText;
	oDivH.appendChild(oDivC);
	document.body.appendChild(oDivH);
}

function dismissLayer( whichLayer )
{
  var elem, vis;
  if( document.getElementById ) // this is the way the standards work
    elem = document.getElementById( whichLayer );
  else if( document.all ) // this is the way old msie versions work
    elem = document.all[whichLayer];
  else if( document.layers ) // this is the way nn4 works
    elem = document.layers[whichLayer];
  vis = elem.style;

  document.body.removeChild(elem);

}

