OverlayPic = new Array();
OverlayPic[0] = new Image(); 
OverlayPic[0].src = "images/ioboard_overlay.png";
OverlayPic[1] = new Image(); 
OverlayPic[1].src = "images/pcbboard_overlay.png";
OverlayPic[2] = new Image(); 
OverlayPic[2].src = "images/backplane_overlay.png";
OverlayPic[3] = new Image(); 
OverlayPic[3].src = "images/cable_overlay.png";

function categoryShoHide(id){
  if (window.document.getElementById(id).style.display == 'none'){
    $('#ioboard').hide('slow');
	$('#pcbboard').hide('slow');
	$('#backplane').hide('slow');
	$('#cable').hide('slow');
	$('#' + id).show('slow');
  }else{
    $('#' + id).hide('slow');
  }
}
function categoryHLight(id)
{
	$('#tt_ioboard').css('color', '#565252');
	$('#tt_pcbboard').css('color', '#565252');
	$('#tt_backplane').css('color', '#565252');
	$('#tt_cable').css('color', '#565252');
	$('#tt_' + id).css('color', '#01B60F');
}
function categoryNoHLight()
{
	$('#tt_ioboard').css('color', '#565252');
	$('#tt_pcbboard').css('color', '#565252');
	$('#tt_backplane').css('color', '#565252');
	$('#tt_cable').css('color', '#565252');
}
function picLoad(id)
{
	window.document.getElementById('OverLayImage').src = OverlayPic[id].src;
	window.document.getElementById('OverLay').style.display = 'block';
}
function picUnload()
{
	window.document.getElementById('OverLayImage').src="images/spacer.gif";
	window.document.getElementById('OverLay').style.display = 'none';
}
function ShowDisclaimer(url,model,flag)
{
	if(model != ''){
		window.document.getElementById('Disclaimernote').innerHTML='By proceeding further you will be accepting the terms and conditions stated in   the 3D disclaimer';
		window.document.getElementById('Disclaimerview').style.display='block';
		if(flag == 0){
			var urlId = url.replace("/pstream/","");
			window.document.getElementById('Disclaimerurltitle').innerHTML = 'Please Login or Register to proceed';
			url = "login-register.html" + urlId;			
		}else{
			window.document.getElementById('Disclaimerurltitle').innerHTML='PROCEED';
		}
	}else{
		window.document.getElementById('Disclaimernote').innerHTML='We apologize for the inconvenience, but at this time the model you have requested is unavailable.  Please contact EDAC if you require further assistance.';
		window.document.getElementById('Disclaimerview').style.display='none';
		window.document.getElementById('Disclaimerurltitle').innerHTML='Contact Us';
		url='contacts.html';
	}
	
	$('#Disclaimer').fadeIn(500);
        //$('#Disclaimerurl').attr('href',url);
        //$('#Disclaimerurl').attr('onclick','');
        $('#Disclaimerurl')[0].onclick = function(){ Popup(url, 750, 700); CloseDisclaimer(); return false; };
		//$('#Disclaimerurl')[0].onclick = window.open(url); CloseDisclaimer(); return false; };
}
function CloseDisclaimer()
{
	$('#Disclaimer').fadeOut(500);
}