// universal dhtml/javascript pulldown menu v1.0 by Andrew Payne droo@clankwerks.com
// please report any bugs or issue to me, for documentation see http://www.clankwerks.com

//browser sniff
is = new BrowserCheck();
function BrowserCheck() {
	var b = navigator.appName
	if (b=="Netscape") this.b = "ns"
	else this.b = b
	this.version = navigator.appVersion
	this.v = parseInt(this.version)
	this.ns = (this.b=="ns" && this.v>=5)
	this.op = (navigator.userAgent.indexOf('Opera')>-1)
	this.safari = (navigator.userAgent.indexOf('Safari')>-1)
	this.op7 = (navigator.userAgent.indexOf('Opera')>-1 && this.v>=7)
	this.ie56 = (this.version.indexOf('MSIE 5')>-1||this.version.indexOf('MSIE 6')>-1)
	this.ie7 = (this.version.indexOf('MSIE 7')>-1)
	this.iewin = (this.ie56 && navigator.userAgent.indexOf('Windows')>-1)
	this.iemac = (this.ie56 && navigator.userAgent.indexOf('Mac')>-1)
	this.moz = (navigator.userAgent.indexOf('Mozilla')>-1)
	this.moz13 = (navigator.userAgent.indexOf('Mozilla')>-1 && navigator.userAgent.indexOf('1.3')>-1) 
	this.oldmoz = (navigator.userAgent.indexOf('Mozilla')>-1 && navigator.userAgent.indexOf('1.4')>-1 || navigator.userAgent.indexOf('Mozilla')>-1 && navigator.userAgent.indexOf('1.5')>-1 || navigator.userAgent.indexOf('Mozilla')>-1 && navigator.userAgent.indexOf('1.6')>-1)
	this.ns6 = (navigator.userAgent.indexOf('Netscape6')>-1)
	this.docom = (this.ie56||this.ns||this.iewin||this.op||this.iemac||this.safari||this.moz||this.oldmoz||this.ns6||this.ie7)
}

var NavMenus = new Array();

//do not alter 0
NavMenus[0] = '<div id="divmenu0" onmouseover="hideall();"><br></div>';

NavMenus[1] = '\
<div class="subnav" id="divmenu1" onmouseover="showpull(\'menu1\')">\n\
<ul class="subnavlist">\n\
<li><a href="/about/index.php">Overview</a></li>\n\
<li><a href="/about/management.php">Management</a></li>\n\
<li><a href="/about/careers.php">Careers</a></li>\n\
<li><a href="/contact/index.php">Contact Us</a></li>\n\
<li><a href="/about/termsofuse.php">Terms of Use</a></li>\n\
<li><a href="/about/privacy.php">Privacy Policy</a></li>\n\
</ul>\n\
</div>\n\
';

NavMenus[2] = '\n\
<div class="subnav" id="divmenu2" onmouseover="showpull(\'menu2\')">\n\
<ul class="subnavlist">\n\
<li><a href="/products/index.php">Products Overview</a></li>\n\
<li><a href="/products/axseries.php">AX Series</a></li>\n\
<li><a href="/products/exseries.php">EX Series</a></li>\n\
<li><a href="/products/idseries.php">ID Series</a></li>\n\
</ul>\n\
</div>\n\
';

NavMenus[3] = '\n\
<div class="subnav" id="divmenu3" onmouseover="showpull(\'menu3\')">\n\
<ul class="subnavlist">\n\
<li><a href="/support/index.php">Support Overview</a></li>\n\
<li><a href="/support/maintenance.php">Maintenance Programs</a></li>\n\
<li><a href="/resources/training.php">Training</a></li>\n\
<li><a href="/support-main/downloads.php"><img src="/images/lock.gif" width="10" height="11" border="0"> Software</a></li>\n\
<li><a href="/support-main/faqs.php"><img src="/images/lock.gif" width="10" height="11" border="0"> FAQs</a></li>\n\
<li><a href="/support-main/appnotes.php"><img src="/images/lock.gif" width="10" height="11" border="0"> Application Notes</a></li>\n\
<li><a href="/support-main/techlibrary.php"><img src="/images/lock.gif" width="10" height="11" border="0"> Technical Library</a></li>\n\
<li><a href="/oss/signup.php">Register</a></li>\n\
</ul>\n\
</div>\n\
';

NavMenus[4] = '\n\
<div class="subnav" id="divmenu4" onmouseover="showpull(\'menu4\')">\n\
<ul class="subnavlist">\n\
<li><a href="/partners.php">Partners Overview</a></li>\n\
<li><a href="/partners-programs.php">Reseller Programs &amp; Levels</a></li>\n\
<li><a href="/partners-tech.php">Technical Partnerships</a></li>\n\
<li><a href="/partners-join/index.php">Become a Reseller</a></li>\n\
<li><a href="/partners-find/index.php">Find a Reseller</a></li>\n\
<li><a href="/partners/proddoc.php"><img src="/images/lock.gif" width="10" height="11" border="0"> Product &amp; Documentation Resources</a></li>\n\
<li><a href="/partners/salesmarketing.php"><img src="/images/lock.gif" width="10" height="11" border="0"> Sales &amp; Marketing Resources</a></li>\n\
<li><a href="/partners/ppc.php"><img src="/images/lock.gif" width="10" height="11" border="0"> A10 Partner Program Overview</a></li>\n\
<li><a href="/oss/signup.php">Register</a></li>\n\
</ul>\n\
</div>\n\
';

NavMenus[5] = '\n\
<div class="subnav" id="divmenu5" onmouseover="showpull(\'menu5\')">\n\
<ul class="subnavlist">\n\
<li><a href="/resources/solutionsheets.php">Solution Briefs</a></li>\n\
<li><a href="/resources/whitepapers.php">White Papers</a></li>\n\
<li><a href="/resources/videos.php">Videos</a></li>\n\
<li><a href="/resources/datasheets.php">Data Sheets & Brochures</a></li>\n\
<li><a href="/resources/deployment_guides.php">Deployment Guides</a></li>\n\
<li><a href="/resources/casestudies.php">Case Studies</a></li>\n\
<li><a href="/resources/customers.php">A10 Customers</a></li>\n\
<li><a href="/resources/customer_quotes.php">Customer Quotes</a></li>\n\
<li><a href="/resources/training.php">Training</a></li>\n\
<li><a href="/resources/performance-reports.php">Performance Reports</a></li>\n\
<li><a href="/resources/logosphotos.php">Logos, Illustrations &amp; Photos</a></li>\n\
</ul>\n\
</div>\n\
';

NavMenus[6] = '\n\
<div class="subnav" id="divmenu6" onmouseover="showpull(\'menu6\')">\n\
<ul class="subnavlist">\n\
<li><a href="/news/index.php">Press Releases</a></li>\n\
<li><a href="/news/indcoverage.html">In the Press</a></li>\n\
<li><a href="/newsletters/">Newsletters</a></li>\n\
<li><a href="/news/awards.php">Awards</a></li>\n\
<li><a href="/news/events.php">Events &amp; Seminars</a></li>\n\
<li><a href="http://twitter.com/a10networks">Twitter</a></li>\n\
<li><a href="http://www.facebook.com/pages/San-Jose/A10-Networks/133959183559">Facebook</a></li>\n\
</ul>\n\
</div>\n\
';

NavMenus[7] = '\n\
<div class="subnav" id="divmenu7" onmouseover="showpull(\'menu7\')">\n\
<ul class="subnavlist">\n\
<li><a href="/solutions/application_solutions.php">Application Solutions</a></li>\n\
<li><a href="/products/axseries.php">Application Delivery</a></li>\n\
<li><a href="/products/axseries-gslb.php">Global Server Load Balancing</a></li>\n\
<li><a href="/products/axseries-carrier_solutions.php">Carrier Solutions (LSN, DS-Lite, IPv6)</a></li>\n\
<li><a href="/products/axseries-cloud_virtualization.php">Cloud Computing and Virtualization</a></li>\n\
<li><a href="/industry/education.php">Education Solutions</a></li>\n\
<li><a href="/products/exseries.php">Bandwidth Management</a></li>\n\
<li><a href="/products/idseries.php">Identity Management</a></li>\n\
</ul>\n\
</div>\n\
';

NavMenus[8] = '\n\
<div class="subnav" id="divmenu8" onmouseover="showpull(\'menu8\')">\n\
<ul class="subnavlist">\n\
<li><a href="http://www.a10networks.com.cn">Chinese</a></li>\n\
<li><a href="/landing/french.php">French</a></li>\n\
<li><a href="/landing/german.php">German</a></li>\n\
<li><a href="/japan/index.php">Japanese</a></li>\n\
</ul>\n\
</div>\n\
';


//get position and move hidden div
function openpull(pullname, xoff, yoff, pulldiv){
		if (xoff == null){ xoff = 0; }
		if (yoff == null){ yoff = 0; }
	
        var popupObj = document.getElementById('div'+pullname);

		var ptop = plft = 0;
		var callerObj = document.getElementById(pullname);
		
			  while(callerObj){
				plft = plft + callerObj.offsetLeft;
				ptop = ptop + callerObj.offsetTop;
				callerObj = callerObj.offsetParent;
			}

		plft = plft + xoff;
		ptop = ptop + yoff;
		popupObj.style.top=ptop+'px';
		popupObj.style.left=plft+'px';
    
                
		if (pulldiv != 'off'){
			hideall();
			showpull(pullname);
		}
}

// position off div
function moveoff(){
	var n = 0;

	while (document.getElementById('menu'+n)){
		document.getElementById('menu0').innerHTML = document.getElementById('menu0').innerHTML+NavMenus[n];
		n++;
	}
	

	var n = 1;
	while (document.getElementById('menu'+n)){
		document.getElementById('menu'+n).onmouseover = function(){openpull(this.id,-5,24);};
		document.getElementById('menu'+n).onmouseout = function(){hideall();};
		n++;
	}
	
	 openpull('menu0', 0, 27);
	 
	 
}


// hide all
function hideall(){
	var n = 1;
	
	while (document.getElementById('divmenu'+n)){
			hidepull('menu'+n);
		n++;
	}
}

//hide pull
function hidepull(pullname){
	var pn = 'div'+pullname;
	if (is.docom) {
		document.getElementById(pn).style.visibility="hidden";
		document.getElementById('divmenu0').style.visibility="hidden";
	}else{
		eval(layertype+pn+styletype+'.visibility="hidden"');
		eval(layertype+'divmenu0'+styletype+'.visibility="hidden"');

	}
}

//show pull
function showpull(pullname){
	var pn = 'div'+pullname;
	if (is.docom) {
		document.getElementById(pn).style.visibility="visible";
		document.getElementById('divmenu0').style.visibility="visible";
	}else{
		eval(layertype+pn+styletype+'.visibility="visible"');
		eval(layertype+'divmenu0'+styletype+'.visibility="visible"');
	}
}
