// JavaScript Document
function swap_nav(img_name,type)
	{
		if(img_name != active)
			{
				var img = document.getElementById(img_name);
				var src = img.src;
				if(src.match('_hover'))
					{
						src = src.replace('_hover','');
					}
				if(type != "")
					src = src.replace('.gif','') + type + '.gif';
				else
					src = src.replace('.gif','') + '.gif';
				img.src = src ;
			}
	}
function activate(id)
	{
		for(i = 1;i<7; i++)
			{
				var img = document.getElementById("nav"+i);
				if(img)
					{
						
						active = id;
						var src = img.src;
						if(src.match('_hover'))
							{
								src = src.replace('_hover','');
							}
						if(('nav'+i) == id)
							{
								src = src.replace('.gif','') + '_hover.gif';
							}
						else
							{
								src = src.replace('.gif','') + '.gif';
							}
						img.src = src ;
					}
			}
	}
function preload()
	{
		var hider = document.getElementById('no_show');
		var src,img;
		for(i = 1;i<7; i++)
			{
				img = document.getElementById("nav"+i);
				src = img.src;
				hider.innerHTML += "<img src='"+src.replace('.gif','')+"_hover.gif' />";
			}
		document.getElementById('dropdown').style.display='none';
	}

function show_popup(filename,transp)
	{
		window.open(filename,"requriements","height=600,width=600,scrollbars=yes");
	}
function close_login(transp)
	{
		transp = 0;
		var login = document.getElementById("popup");
		setOpacity(login,transp);
		if(transp > 0)
			{
				setTimeout("close_login("+(transp-20)+")",20);
			}
		else
			{
				login.style.height='0px';
				login.style.overflow = 'hidden';
				login.style.display = 'none';
			}
	}

function setOpacity(testObj,value) {
	testObj.style.opacity = value/100;
	testObj.style.filter = 'alpha(opacity=' + value + ')';
}

function getPageSizeWithScroll(req){
	if (window.innerHeight && window.scrollMaxY) {// Firefox
		yWithScroll = window.innerHeight + window.scrollMaxY;
		xWithScroll = window.innerWidth + window.scrollMaxX;
	} else if (document.body.scrollHeight > document.body.offsetHeight){ // all but Explorer Mac
		yWithScroll = document.body.scrollHeight;
		xWithScroll = document.body.scrollWidth;
	} else { // works in Explorer 6 Strict, Mozilla (not FF) and Safari
		yWithScroll = document.body.offsetHeight;
		xWithScroll = document.body.offsetWidth;
  	}
	arrayPageSizeWithScroll = new Array(xWithScroll,yWithScroll);
	//alert( 'The height is ' + yWithScroll + ' and the width is ' + xWithScroll );
	return arrayPageSizeWithScroll[req];
}

function load_file(filename)
  {
	

  }

