
// For all top level pages
// Need to exclude Mac: somehow the top != self statement is causing abnormal
// behavior in Mac
if (navigator.userAgent.indexOf("Mac")==-1)
{
	if (top != self)
		top.location = self.location;
}
//Newly added for Login popup window

//content fot floting menu
var left1;
var top1;
if(window.screen.width==800 || window.screen.width!=1024)
{
	left1=500
	top1=70
}
else if(window.screen.width==1024)
{
	left1=735
	top1=75	
}
	var RemainingWidth=0;
	var TotalWidth=0;
	var winWidth=0;	
	CalcWinSize();
	document.write("<table width='" + (TotalWidth) +"' border='0' cellspacing='0' cellpadding='0'>");
	
	document.write("<tr><td nowrap >");
	document.write("<table width='100%' border='0' cellspacing='0' cellpadding='0' border='0'>");
	
	document.write("<td	width='0' nowrap valign='bottom'>");


	document.write("<a href='/caw/index.htm'><img src='/caw/img/home_citi_at_work_logo.gif' alt='Citi At Work' border='0'></a><br>");
	winWidth = winWidth - 256;
	//added for tab link- starts
	for ( var i=1;i<tabName.length;i++){
		if (tab == i){			
		document.write("<a id='tab'+i href='" + tabLink[i] + "'  >");
		document.write("<img src='" + tabImgActive[i] + "' alt='" + tabName[i] +"' name='nav_" + tabImgID[i] + "' height='22' border='0' id='nav_" + tabImgID[i] + "' ></a>");
		getWidthofObject('nav_' + tabImgID[i]);
		getWidthofObject('tab' + i);		
		}
		else{
		document.write("<a id='tab'+i href='" + tabLink[i] + "' onMouseOver='navRoll(" + tabImgID[i] + ",1,1)' onMouseOut='navRoll(" + tabImgID[i] + ",0,1)' >");
		document.write("<img src='" + tabImgOff[i] + "' alt='" + tabName[i] +"' name='nav_" + tabImgID[i] + "' height='22' border='0' id='nav_" + tabImgID[i] + "' ></a>");
		getWidthofObject('nav_' + tabImgID[i]);
		getWidthofObject('tab' + i);
		}
		document.write("<img src='/caw/img/nav/b_line.gif' width='5' height='22' border='0'>");
		winWidth = winWidth -5;
	}
	document.write("</td>");
    //ends

		document.write("<td width='100%' valign='bottom'><img src='/caw/img/nav/b_line.gif' width='100%' height='22' ></td>");
	document.write("</tr>");
	document.write("</table>");
	document.write("</td></tr>");
	document.write("</table>");

function getWidthofObject(objectName)
	{
		if (n==1  )
		{
			objectName ="document." + objectName;
			var obj = eval(objectName)
			if (obj) 
			{
				winWidth = winWidth- obj.width;
			}	
		}	
	}
	function CalcWinSize() 
	{
		if(ns6==1) 
		{
			winWidth=innerWidth;
			TotalWidth=winWidth-14;
			winWidth = winWidth- (444);
			RemainingWidth=winWidth-(444);
		}
		else
		{
			winWidth=window.screen.width;
			TotalWidth="100%";
			RemainingWidth=winWidth-(433);
		}
	}
	var win = null;

function NewWindow(mypage,myname,w,h)
	{
		LeftPosition = (screen.width) ? (screen.width-w)/2 : 0;
		TopPosition = (screen.height) ? (screen.height-h)/2 : 0;
		settings ='height='+h+',width='+w+',top='+TopPosition+',left='+LeftPosition+',scrollbars=yes,resizable';
		win = window.open(mypage,myname,settings)
	}
