window.onload = init;

function init()
{
	var a = document.getElementsByTagName("DIV")
	
	for( i=0; i<a.length;i++ )
	{
		if( a[i].className )
		{
			if( a[i].className == 'nav2' )
			{
				a[i].onmouseover = function()
				{
					if(document.getElementById('sub_'+this.id.split('_')[0]))
						document.getElementById('sub_'+this.id.split('_')[0]).style.display = 'block'
				}
				
				a[i].onmouseout = function()
				{
						if( document.getElementById('sub_'+this.id.split('_')[0]))
							document.getElementById('sub_'+this.id.split('_')[0]).style.display = 'none'
				}
			}
			
			if(a[i].className == 'subtier' )
			{
				a[i].onmouseover = a[i].onfocus = function()
				{
					if(document.getElementById(this.id)){
						document.getElementById(this.id).style.display = 'block';						   
					}
					
					//Tier Nav
					/*newid = this.id.split('_')[1]
					if( document.getElementById('tier_'+newid))
					thesub = document.getElementById('tier_'+newid)
					thesub.style.display = 'block'*/
				}
				
				a[i].onmouseout = a[i].onblur = function()
				{
					//Tier Nav
					/*newid = this.id.split('_')[1]
					if( document.getElementById('tier_'+newid))
					thesub = document.getElementById('tier_'+newid)
					thesub.style.display = 'none'*/
				}
			}
		}
	}
	
}

