//December 2004 version
		// debug: uncomment this to turn debugging on so we don't need to use netscape
		//	self.onerror = function showErr(msg,url,line) {
		//		alert("ERROR: "+msg+"\nline: "+line);
		//	}
			// Popup Windows
			function popup (url,width,height,name) {
				var w = window.open (url,name,"toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width=" + width + ",height=" + height,true);
				w.focus();
				if(arguments.length >= 5) {
					return w;
				}
			}
			// Printing
			function printThisPage() {
				var url = String(window.location);
				if (url.indexOf('?') == -1) {
					url += "?";
				} else {
					url += "&";
				}
				url += "p=t";
				var w = popup(url, 800, 500, "print", true);
			}
			function callPrinter() {
				if (self.print) {
				  setTimeout("self.print()", 3000);
				}
			}
		// Rollovers
			function preload(name, on_image, off_image) {
				eval(
					name + "_on = new Image();" + 
					name + "_on.src = \"" + on_image + "\";" + 
					name + "_off = new Image();" + 
					name + "_off.src = \"" + off_image + "\";"
				);
			}
			function loadImage(name, img) {
				if (document.images) {
					document.images[name].src = img.src;
				}
			}
		// Navigation Fade
			var image_list;
			var rate = 1;
			function fadeNav(name) {
				if (document.images) {
					image_list = new Array();
					image_list[0] = new Image();
					image_list[0].src = "//a248.e.akamai.net/f/248/5462/2h/www.symantecstore.com/v2.0-img/images/symant73/met/phase1nav/final/swoop0.gif";
					image_list[1] = new Image();
					image_list[1].src = "//a248.e.akamai.net/f/248/5462/2h/www.symantecstore.com/v2.0-img/images/symant73/met/phase1nav/final/swoop1.gif";
					image_list[2] = new Image();
					image_list[2].src = "//a248.e.akamai.net/f/248/5462/2h/www.symantecstore.com/v2.0-img/images/symant73/met/phase1nav/final/swoop2.gif";
					image_list[3] = new Image();
					image_list[3].src = "//a248.e.akamai.net/f/248/5462/2h/www.symantecstore.com/v2.0-img/images/symant73/met/phase1nav/final/swoop3.gif";
					imageSequence(name, 0);
				}
			}
			function imageSequence(name, index) {
				if (index > image_list.length - 1) {
					return;
				}
				if (document.images) {
					if (document.images[name].filters) {
						document.images[name].style.filter="blendTrans(duration=rate)";
						document.images[name].filters.blendTrans.Apply();
					}
					document.images[name].src = image_list[index].src;
					if (document.images[name].filters) {
						document.images[name].filters.blendTrans.Play();
					}
					
					setTimeout("imageSequence(\"" + name + "\", " + ++index + ")", rate * 1000);
				}
			}
		// Menus
			var timerID = null; 
			var timerOn = false; 
			var timecount = 500; 
			var check = false;
			function getPos(element, which) {
				pos = 0
				while (element != null) {
					pos += element["offset" + which]
					element = element.offsetParent
				}
				return pos;
			}
			function show(name) {
						var elem = document.getElementById(name);
						var parent = elem.parentNode;
						if (elem != null) {
							elem.style.visibility="visible";
							elem.style.display="block";
							elem.style.left=(getPos(parent, "Left") + 10) + "px";
							elem.style.top=(getPos(parent, "Top") + 18) + "px";
						}
			}
			function hide(name) {
						var elem = document.getElementById(name);
						if (elem != null) {
							elem.style.visibility="hidden";
							elem.style.display="none";
						}
			}
			var Divs = new Array();
			Divs[0] = "utility_symantec";
			Divs[1] = "utility_about";
			Divs[2] = "utility_i18n";
			Divs[3] = "utility_login";
			function hideAll(omit) {
				for (i = 0; i < Divs.length; i++) {
					if (omit != Divs[i]) {
						hide(Divs[i]);
					}
				}
			}
			function startTime() {
				if (timerOn == false) {
					timerID = setTimeout("hideAll()", timecount);
					timerOn = true;
				}
			}
			function stopTime() {
				if (timerOn) {
					clearTimeout(timerID);
					timerID = null;
					timerOn = false;
				}
			}
		// Product Selector
		var prod_selector = new Object();
		prod_selector.anchorDivId = ""; prod_selector.anchorBtmId=""; prod_selector.primaryWidth = 0; prod_selector.secondaryWidth = 0;
		prod_selector.mouseOverImg = ""; prod_selector.normalImg = ""; prod_selector.topStatusTxt = ""; prod_selector.bgColorClass = "";
		prod_selector.itemBorderClass = ""; prod_selector.menuGraphicClass = ""; prod_selector.btmBorderClass = ""; 
		prod_selector.itemContentClass = ""; prod_selector.objWinHgt = ""; prod_selector.objScrollOffset = ""; prod_selector.objWinWidth = "";
		prod_selector.spacerGifPath = "//a248.e.akamai.net/f/248/5462/2h/www.symantecstore.com/v2.0-img/images/symant73/met/pixel.gif"; prod_selector.browser = ""; prod_selector.tOffset = 0; prod_selector.invTOfsset = 0;
		prod_selector.iemac = false; prod_selector.psLayers = new Array();
		
		var mItems = new Array();
		var lList = new Object();
		var selTmrId = null; 
		var selTmrOn = false; 
		var selTmrCnt = 700; 
		prod_selector.iemac = (navigator.userAgent.indexOf('MSIE 5') != -1 && navigator.userAgent.indexOf('Mac') != -1);
		if(document.layers) { // NS 4.x specific
			var origWidth = window.innerWidth;
			var origHeight = window.innerHeight;
			window.onresize = function() {
													if(window.innerWidth != origWidth || window.innerHeight != origHeight) {//extra code to ensure a genuine resize has occurred
														origWidth = window.innerWidth; 
														origHeight = window.innerHeight;
														window.location.reload();
													}
														};
		} // end NS4.x block
		function window_on_load () {
			if(document.getElementById) {
				window.onresize = function() {calculate_lOffset()};
				var top = document.getElementById('prod-selector'); 
				if(top) {
						getHghts(); getInvs(); calculate_lOffset();calculate_TOffsets();
						top.onmouseover = function(){window.status = prod_selector.topStatusTxt; showSelDiv('level-1', prod_selector.anchorBtmId); selstop();};
						top.onmouseout = function(){window.status=''; selstart();};
						top=null;;
				}
			}
		}
		function calculate_lOffset() {
			if(prod_selector.secondaryWidth > 0) {
				var right_terminus = getPos(document.getElementById(prod_selector.anchorDivId), 'Left') + prod_selector.primaryWidth + prod_selector.secondaryWidth;
				if(right_terminus <= eval(prod_selector.objWinWidth) || prod_selector.iemac) {
					prod_selector.leftOffset = prod_selector.primaryWidth + 1;
				} else {
					prod_selector.leftOffset = (-1 * prod_selector.secondaryWidth) - 2;
				}
			}
		}
		function calculate_TOffsets() { //values determined empirically
			if(prod_selector.browser == 'IE' && !(prod_selector.iemac)) {
				prod_selector.tOffset = 0;
				prod_selector.invTOfsset = -1;
			} else {
				prod_selector.tOffset = -1;
				prod_selector.invTOfsset = 0;
			}
		}
		function setobjs(){
			if(navigator.userAgent.indexOf('Safari') != -1)	{
				prod_selector.objWinHgt = 'window.innerHeight';
				prod_selector.objScrollOffset = 'window.pageYOffset';
				prod_selector.objWinWidth = 'window.innerWidth';
				prod_selector.browser = 'Safari';
			}
			else if(window.innerHeight) { //NS
				prod_selector.objWinHgt = 'window.innerHeight';
				prod_selector.objScrollOffset = 'window.pageYOffset';
				prod_selector.objWinWidth = 'window.innerWidth';
				prod_selector.browser = 'Mozilla';
			}	
			else if(document.body.clientHeight) { //IE
				prod_selector.objWinHgt = 'document.body.clientHeight';
				prod_selector.objWinWidth = 'document.body.clientWidth';
				prod_selector.objScrollOffset = 'document.body.scrollTop';
				prod_selector.browser = 'IE';
			}
		}
		function mustInv(toShow){
			var inv = false;
			var lTop = getPos(prod_selector.psLayers[lList[toShow]].lock, "Top");
			if((lTop + prod_selector.psLayers[lList[toShow]].height) >= (eval(prod_selector.objWinHgt) + eval(prod_selector.objScrollOffset)) && (lTop - prod_selector.psLayers[lList[toShow]].height > 15)) inv = true;
			return inv;
		}
		function showSelDiv(toshow, lockto){
						if(prod_selector.psLayers.length > 0) {
								var ptr = document.getElementById(toshow);
								var inv = mustInv(toshow);
								if((!(prod_selector.iemac) && inv) || (prod_selector.iemac && toshow != 'level-1' && inv))
								{
										var oLft = (toshow == 'level-1') ? 0 : prod_selector.leftOffset;
										var oTop = 0;
										ptr.style.visibility="visible";
										ptr.style.display="block";
										ptr.style.left= (getPos(prod_selector.psLayers[lList[toshow]].inv_lock, 'Left') + oLft) + "px";
										ptr.style.top = '';
										ptr.style.top= (getPos(prod_selector.psLayers[lList[toshow]].inv_lock, 'Top') - (prod_selector.psLayers[lList[toshow]].height + prod_selector.invTOfsset)) + "px";
								}
								else
								{
										var offsetLeft = (toshow == 'level-1') ? (0) : prod_selector.leftOffset;
										var offsetTop = 0;
										ptr.style.visibility="visible";
										ptr.style.display="block";
										ptr.style.left= (getPos(prod_selector.psLayers[lList[toshow]].lock, 'Left') + offsetLeft) + "px";
										ptr.style.top = ''; //odd hack, necessary to accomodate ie on the mac!
										ptr.style.top = (prod_selector.iemac) ? ((lockto == prod_selector.anchorBtmId) ? '' : (getPos(prod_selector.psLayers[lList[toshow]].lock, 'Top') + prod_selector.tOffset) + "px") : ((getPos(prod_selector.psLayers[lList[toshow]].lock, 'Top') + prod_selector.tOffset) + "px");
								}
						}
		}
		function selstart() {
			if (selTmrOn == false) {
				selTmrId = setTimeout("hideselall()", selTmrCnt);
				selTmrOn = true;
			}
		}
		function selstop() {
			if (selTmrOn) {
				clearTimeout(selTmrId);
				selTmrId = null;
				selTmrOn = false;
			}
		}
		function hideselall() {
			if(arguments.length != 0)
			{
				var exclude;
				for (var i = 0; i < prod_selector.psLayers.length; i++)
				{
					exclude = false;
					for(var ii = 0; ii < arguments.length; ii++)
					{
						if(prod_selector.psLayers[i].id == arguments[ii])
						{
							exclude = true;
							break;
						}
					}
					if(!(exclude))
					{
						hide(prod_selector.psLayers[i].id);
					}
				}
			}
			else
			{
				for (var i = 0; i < prod_selector.psLayers.length; i++)
				{
					hide(prod_selector.psLayers[i].id);
				}
			}
		} 
		function hvr(ID, href, value){
				window.status = href; 
				document.getElementById((ID)).style.backgroundColor = (value) ? "#f27f1a" : ""; //TBD: color in a variable
				document.getElementById(('td-' + ID)).style.color = (value) ? "#ffffff" : ""; //TBD: color in a variable
				if(document.images[('img-' + ID)]) document.images[('img-' + ID)].src = (value) ?  prod_selector.mouseOverImg : prod_selector.normalImg;
			}
		function copyArray(arrToCopy){
			var temp = new Array();
			for(var i=0; i < arrToCopy.length; i++)
			{
				temp[i] = arrToCopy[i];
			}
			return temp;
		}
		function initiateBuild()
		{
			 if(mItems.length != 0)
			 {
				buildSel(mItems);
			}
		}
		function buildSel(arrInfo){
			var markup, itemMU;
			var styleOverride = '';
			var arrArg;
			var xclusion;
			var containingLayer;
			var width;
			var zIndex;
			if(arguments.length == 1) //first time in
			{
				setobjs();
				width = prod_selector.primaryWidth ;
				containingLayer = 'level-1' ;
				var elem = new Object();
				elem['id'] = containingLayer;
				elem['top'] = 0;
				elem['height'] = 0;
				prod_selector.psLayers[0] = elem;
				xclusion = "'" + containingLayer + "'";
				arrArg = new Array(containingLayer);
			}
			else //recursion
			{
				width = prod_selector.secondaryWidth; //TBD: needs to be tweaked, or perhaps controllable dynamically;
				containingLayer = arrInfo[0].parent + '-sub';
				var surr =  arguments[1];
				//build the exclusion list: 
				for(x=0; x < surr.length; x++)
				{
					xclusion = (x==0) ? ("'" + surr[x] + "'") : (xclusion + ",'" + surr[x] + "'");
				}
				xclusion += ",'" + containingLayer + "'";
				arrArg = copyArray(arguments[1]); //copy to augment
				arrArg[arrArg.length] = containingLayer;
			}
			styleOverride = ' style="width:' + width + 'px;"';
			zIndex = arguments.length == 1 ? 1 : 2;
			markup = '<div id="' + containingLayer + '" style="z-Index:' + zIndex + '; position:absolute; visibility:hidden; " onMouseOver="selstop();" onMouseOut="selstart();">';
			markup += '\n<table class="' + prod_selector.bgColorClass + '" width="' + width + '" border="0" cellspacing="0" cellpadding="0">\n';
			itemMU = '';
			//for each menu item:
			for(var i=0; i < arrInfo.length; i++)
			{
				var thisExclusion = '';
				var obj = arrInfo[i];
				var aParent = (obj.sub_nav && obj.sub_nav.length >= 1);
				itemMU += '<tr>';
				if(i == arrInfo.length - 1)
				{
					itemMU += '<td  class="' + prod_selector.btmBorderClass + '">';
					
				} else {
					itemMU += '<td  class="' + prod_selector.itemBorderClass + '">';
				}
				itemMU += '<div id="' + obj.id + '" onClick="window.location=' + "'" + obj.link + "'" + ';"';
				itemMU += ' onMouseOver="hvr(' + "'" + obj.id + "'" + ', ' + "'" + obj.link + "'" + ', true); ';
				/* extra mouseover code here: */
				thisExclusion = ' hideselall(';		
				if(aParent) //if there are children, we have to *show* specific layers, as well as hide others
				{
					thisExclusion += xclusion + ",'" +obj.id + "-sub'" + "); showSelDiv('" + obj.id + "-sub', " + "'" + obj.id + "', '" + containingLayer + "');" + ' selstop();" ';
				}
				else //just hide the others
				{
					thisExclusion += xclusion + ');" ';
				}
				itemMU += thisExclusion;
				itemMU += 'onMouseOut="hvr(' + "'" + obj.id + "'" + ', ' + "''," + ' false);" ';
				itemMU += ' style="width:' + width + 'px;">\n';;  
				itemMU += '<table class="" border="0" cellspacing="0" cellpadding="0">\n';
				var dynamWidth = width - 5; //5 is the width of the arrow graphic
				itemMU += '<tr><td id="td-' + obj.id + '" class="' + prod_selector.itemContentClass + '" >' + obj.text + '</td>';
				//do we need to add the arrow, which signifies that the menu item has children?
				var rightMostCell = (aParent) ? '<img id="img-' + obj.id + '" src="' + prod_selector.normalImg + '" width="5" height="9" border="0">' : '';
				itemMU += '<td class="' + prod_selector.menuGraphicClass + '" >' + rightMostCell + '</td>';
				itemMU += '</tr></table>\n</div></td></tr>\n';
				if(aParent) //recurse
				{
					buildSel(obj.sub_nav, arrArg)
				}
			}
			markup += itemMU;
			markup += '</table>\n<div id="' + containingLayer + '-bottom"><img src="' + prod_selector.spacerGifPath + '" width="1" height="1" alt="" border="0">' + '</div>\n</div>';
			document.write(markup);
			if(containingLayer != 'level-1')
			{
				var elem = new Object();
				elem['id'] = containingLayer;
				elem['height'] = 0;
				prod_selector.psLayers[prod_selector.psLayers.length] = elem;
			}
		}
		function fetchNode(id, arrToSearch){
			var found = null;
			for(var i=0; i <= arrToSearch.length - 1; i++)
			{
				var current = arrToSearch[i];
				if(current['id'])
				{
					if(current['id'] == id)
					{
						found = current;
						break;
					}
				}
				if(current['sub_nav'] && current['sub_nav'].length >= 1)
				{
					found = fetchNode(id, current['sub_nav']);
					if(found) break;
				}
			}
			return found;
		}
		function buildNode(parentID, id, txt, href, hasSub){
		if(parentID == prod_selector.anchorDivId)
			{
				mItems[mItems.length] = new Object();
				var node = mItems[mItems.length - 1];
				node['id'] = id;
				node['text'] = txt;
				node['link'] = href;
				//does this have children?
				if(hasSub) node['sub_nav'] = new Array();
			}
			else //build subordinate item:
			{
				var parent = fetchNode(parentID, mItems);
				if(parent)
				{
					if(!parent['sub_nav']) parent['sub_nav'] = new Array();
					var sub = parent['sub_nav'][parent['sub_nav'].length] = new Object();
					sub['parent'] = parent.id;
					sub['id'] = id;
					sub['text'] = txt;
					sub['link'] = href;
					//Does this have a sub nav?
					if(hasSub) sub['sub_nav'] = new Array();
				}
			}
		}
		function getHghts(){
			for(var i=0; i < prod_selector.psLayers.length; i++)
			{
				var posID;
				var id; 
				if(i==0) //level-1
				{
					posID = prod_selector.anchorBtmId;
					id = 'level-1';
				}
				else //the subs
				{
					posID = prod_selector.psLayers[i].id.substr(0, prod_selector.psLayers[i].id.indexOf('-sub'));
					id = prod_selector.psLayers[i].id;
				}
			//positioning element:
			var posEl = document.getElementById(posID);
			//element to be positioned:
			var el = document.getElementById(id);
			var top = getPos(posEl, "Top");
			el.style.top = top  + "px";
			var bottom = document.getElementById(id + '-bottom');
			var Hght = getPos(bottom, "Top") - top;
			prod_selector.psLayers[i].height = Hght;
			if(i==0)
				{
					prod_selector.psLayers[i]['lock'] = document.getElementById(prod_selector.anchorBtmId);
				}
				else
				{
					prod_selector.psLayers[i]['lock'] = posEl;
				}
				//put entry in the linked list:
				lList[id] = i;
			}
		}
		var getInvs="function getInvs() {"; 
		getInvs += "for(var i=0; i < prod_selector.psLayers.length; i++){";
		getInvs += "switch(i) {";
		getInvs += "case 0:";
		getInvs += "prod_selector.psLayers[i]['inv_lock'] = document.getElementById(prod_selector.anchorDivId); break;";
		getInvs += "case (prod_selector.psLayers.length - 1):";
		getInvs += "prod_selector.psLayers[i]['inv_lock'] = document.getElementById('level-1-bottom'); break;";
		getInvs += "default:";
		getInvs += "prod_selector.psLayers[i]['inv_lock'] = prod_selector.psLayers[i + 1]['lock'];}";
		getInvs += "} }";
		eval(getInvs);
		
		//</dsp:page>