var popUpWin=0;

function OpenWinAcces(){
document.all['WinAccess'].style.display = 'inline';
document.all['WinAccess'].style.visibility = 'visible';
}

function CloseWinAcces(){
document.all['WinAccess'].style.visibility = 'hidden';
document.all['WinAccess'].style.display = 'none';
}

function popUpWindow(URLStr, left, top, width, height)
{
if(popUpWin)
{
  if(!popUpWin.closed) popUpWin.close();
}
html = "<html><head><title>IMS Interactive</title></head><body bottommargin=0 leftmargin=0 marginheight=0 marginwidth=0 rightmargin=0 topmargin=0 bgcolor='#FFFFFF' style='overflow: hidden;'>\n"+
"<a href='javascript: window.close();'><img width="+
width +
" height=" +
height +
" src='"+
URLStr +
"' border=0 alt='Закрыть' /></a></body></html>";
popUpWin = window.open(URLStr, 'popUpWin', 'toolbar=no,location=no,directories=no,status=0,menub ar=no,scrollbar=no,resizable=no,copyhistory=yes,width='+width+',height='+height+',left='+left+', top='+top+',screenX='+left+',screenY='+top+'');
popUpWin.document.open();
popUpWin.document.write(html);
popUpWin.document.close();
}

if (navigator.platform == "Win32" && navigator.appName == "Microsoft Internet Explorer" && window.attachEvent) {
	window.attachEvent("onload", alphaBackgrounds);
}

function alphaBackgrounds(){
	var rslt = navigator.appVersion.match(/MSIE (\d+\.\d+)/, '');
	var itsAllGood = (rslt != null && Number(rslt[1]) >= 5.5);
	for (i=0; i<document.all.length; i++){
		var bg = document.all[i].currentStyle.backgroundImage;
		if (itsAllGood && bg){
			if (bg.match(/\.png/i) != null){
				var mypng = bg.substring(5,bg.length-2);
				
				document.all[i].style.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+mypng+"', sizingMethod='scale')";
				document.all[i].style.backgroundImage = "url(img/d-t.gif')";
			}
		}
	}
}