
	function popup(url,h,w, x, y) 
	{ // (url,height,width, top, left)
			var p = "height=" + h + ",width=" + w + ", top=" + x + ", left=" + y + ", scrollbars=no";
			window.open(url,"",p);
	} 

	<!--
		function popupscroll(url,h,w, x, y) { // (url,height,width, top, left)
			var p = "height=" + h + ",width=" + w + ", top=" + x + ", left=" + y + ", scrollbars=yes";
			window.open(url,"",p);
	} // -->


function getRandom(maxNum)
{
  if (Math.random && Math.round)
  {
    var ranNum= Math.round(Math.random()*(maxNum-1));
    ranNum+=1;
    return ranNum;
  }
  else
  {
  today= new Date();
  hours= today.getHours();
  mins=   today.getMinutes();
  secn=  today.getSeconds();
  if (hours==19)
   hours=18;
  var ranNum= (((hours+1)*(mins+1)*secn)%maxNum)+1;
  return ranNum;
  }
}

function setStatusBar(msgStr) { self.status = msgStr; }

var homeSideRandomNumber = getRandom(10);
function writeHomeSideImage(picIndex)
{
	var codeTemp = '<img src="/home/sideimages/' + homeSideRandomNumber + '/' + picIndex + '.gif" name="sidePic' + picIndex + '" width="40" height="40" id="sidePic' + picIndex + '" >';
	document.write(codeTemp);
}



var randomNumber06 = getRandom(15);
function writeTopImage06(picIndex)
{
	//var codeTemp = '<img src="/common/graphics/toppics/0607/' + randomNumber06 + '/' + picIndex + '.gif" name="topPic' + picIndex + '" width="40" height="40" id="toppic' + picIndex + '" style="Filter: Gray">';
	
	var codeTemp = '<img src="/common/graphics/toppics/0607/' + randomNumber06 + '/' + picIndex + '.gif" name="topPic' + picIndex + '" width="40" height="40" id="toppic' + picIndex + '" >';
	
	//var codeTemp = '<img src="/common/graphics/toppics/pink/' + picIndex + '.gif" name="topPic' + picIndex + '" width="40" height="40" id="toppic' + picIndex + '">';


	document.write(codeTemp);

}
function writeTopImagePink(picIndex)
{
	var codeTemp = '<img alt="Help our Charity Team raise month this week!" src="/common/graphics/toppics/pink/' + picIndex + '.gif" name="topPic' + picIndex + '" width="40" height="40" id="toppic' + picIndex + '">';


	document.write(codeTemp);

}



function writeTopImage(picIndex)
{
	var randomNumber = getRandom(13);
	//var codeTemp = '<img src="/common/graphics/toppics/' + picIndex + '/' + randomNumber + '.gif" name="topPic' + picIndex + '" width="40" height="40" id="toppic' + picIndex + '" style="Filter: Gray">';
	var codeTemp = '<img src="/common/graphics/toppics/' + picIndex + '/' + randomNumber + '.gif" name="topPic' + picIndex + '" width="40" height="40" id="toppic' + picIndex + '">';
	
	//var codeTemp = '<img src="/common/graphics/toppics/0607/' + randomNumber + '/' + picIndex + '.gif" name="topPic' + picIndex + '" width="40" height="40" id="toppic' + picIndex + '">';
	
	document.write(codeTemp);

}

function writeDate()
{
	var d=new Date()
	var weekday=new Array("Sun","Mon","Tuesday","Wed","Thu","Fri","Saturday")
	var monthname=new Array("January","February","March","April","May","June","July","August","September","October","Nov","December")
	document.write(":: It\'s " + weekday[d.getDay()] + ",  ")
	document.write(d.getDate() + " ")
	document.write(monthname[d.getMonth()] + ", ");
	document.write(d.getFullYear())
}


function getWindowSize()
{
	windowWidth = document.body.clientWidth;
	windowHeight = document.body.clientHeight;

	//alert("height = " + windowHeight + "    width = " + windowWidth );


		if (windowHeight < 591)
		{
			myContentHeight = 250;
		}
		else
		{
			myContentHeight = 420;
		}
		
	myContentWidth = 170;
}

		

	function changeCell(which, flag)
	{
		//alert(flag);
		
		if (flag==1)
		{
   			which.style.backgroundColor="#cc0000"; //#ff0000#FF00CC#0000ff
		}
		else
		{
			if (flag==2)
			{
   				which.style.backgroundColor="#008000"; //FF66CC/#ffd2d2//0000ff
			}
			else
			{
				if (flag==3)
				{
   					which.style.backgroundColor="#C1F2B5"; //#FFCCFF#8fe7ff
				}
				else
				{
					if (flag==4)
					{
						which.style.backgroundColor="#ffffff";
					}
					else
					{
						// 5 (red) and 6 (blue) added for Washington pafe
						if (flag==5)
						{
							which.style.backgroundColor="#ff0000";
						}
						else
						{
							if (flag==6)
							{
								which.style.backgroundColor="#0000ff";
							}
							else
							{
   								which.style.backgroundColor="#ffffff";
							}
						}
					}
				}
			}		
		}
	}
	
	function changeCellAdmin(which, flag)
	{
		//alert(flag);
		
		if (flag==1)
		{
   			which.style.backgroundColor="#000000";
		}
		else
		{
   			which.style.backgroundColor="#c0c0c0";		
		}
	}
	
	
	
var speed=0;


function increaseSpeed() 
{
	speed = speed + 5;
}

function resetSpeed() 
{
	speed = 5;
}

function changeScrollers(imageID, state) 
{
	//alert("ID is:" + imageID + "  state is: " + state);

	if (imageID=="down")
	{
		if (state == "over")
		{
			var temp = "document.scrollDown.src = '/common/graphics/scrolldownOver.gif'";	
		}
		else
		{
			var temp = "document.scrollDown.src= '/common/graphics/scrolldown.gif'";	
		}

	}
	else
	{
		if (state == "over")
		{
			var temp = "document.scrollUp.src= '/common/graphics/scrollupOver.gif'";	
		}
		else
		{
			var temp = "document.scrollUp.src= '/common/graphics/scrollup.gif'";	
		}

	}
	eval(temp);

	
}

													
	
	function stuff()
	{
		//alert("stuff");
		
		//Scrollable content script II- © Dynamic Drive (www.dynamicdrive.com)
		iens6=document.all||document.getElementById


		//specify speed of scroll (greater=faster)
		speed=4;
												
		windowWidth = document.body.clientWidth;
		windowHeight = document.body.clientHeight;
												
		//alert(windowHeight);

		if (windowHeight < 590)
		{
			var myContentHeight = 220;
		}
		else
		{
			var myContentHeight = 280;
		}
		
		//alert(myContentHeight);									
											
		document.write('<div id="container" style="position:relative; width:150; top:5; bottom:0; height: ' + myContentHeight + '; border:0px solid black;overflow:hidden">')
											
		document.write('<div id="content" style="position:relative;width:140;left:5; top:0; bottom:0; border:0px solid red">')
	}
	

	
	
	function movedown()
	{

		var crossobj=document.getElementById? document.getElementById("content") : document.all.content
		var contentheight=crossobj.offsetHeight
	
	
		if (iens6&&parseInt(crossobj.style.top)>=(contentheight*(-1)+100))
			crossobj.style.top=parseInt(crossobj.style.top)-speed
			
		movedownvar=setTimeout("movedown()",100)
	}

	function moveup()
	{
	
		var crossobj=document.getElementById? document.getElementById("content") : document.all.content
		var contentheight=crossobj.offsetHeight
	
		if (iens6&&parseInt(crossobj.style.top)<=0)
			crossobj.style.top=parseInt(crossobj.style.top)+speed
		else if (ns4&&crossobj.top<=0)
		crossobj.top+=speed
		
		moveupvar=setTimeout("moveup()",100)

	}

	function changeOpacity(imageID, newOpacity)
	{
		//var temp= 'document.imgMain.style.filter:alpha(opacity=' + newOpacity + ')';
		var temp= 'document.img' + imageID + '.filters.alpha.opacity = ' + newOpacity;
		eval(temp);
	}
	
function showDownloadHelp()
{
	if (downloadHelpStatus=="hidden")
	{
		document.getElementById("divDownloadHelp1").style.visibility='visible';
		document.getElementById("divDownloadHelp2").style.visibility='visible';
		downloadHelpStatus = "visible";
	}
	else
	{
		document.getElementById("divDownloadHelp1").style.visibility='hidden';
		document.getElementById("divDownloadHelp2").style.visibility='hidden';
		downloadHelpStatus = "hidden";	
	}
}



var doAlerts=false;
function changeStyleSheets(whichSheet)
{
  whichSheet=whichSheet-1;
	//styleSheet = whichSheet;
	//alert(styleSheet);

  if(document.styleSheets)
  {
    var c = document.styleSheets.length;
    if (doAlerts) alert('Change to Style '+(whichSheet+1) + " c = " + c);
	//alert("whichSheet = " + whichSheet);
    for(var i=0;i<c;i++)
	{
		//alert("doing: " + i);
      	if(i!=whichSheet)
	  	{
        	document.styleSheets[i].disabled=true;
					//alert("disabled " + i);
      	}
		else
	  	{
        	document.styleSheets[i].disabled=false;
					//alert("NOT disabled " + i);
      	}
    }	
  }

	var numberFrames = document.frames.length;
  	if (numberFrames > 0)
  	{
  		if (whichSheet == 0)
  		{
			var newBackgroundColor = "#e0e0d0";
  		}
  		else
  		{
			var newBackgroundColor = "#ffffff";	  
  		}
		//alert("whichSheet = " + whichSheet);
  		for(var i=0;i<numberFrames;i++)
		{
        	//document.frames[i].document.body.style.backgroundColor= newBackgroundColor;
			//alert(" i = " + i);
    
			var x = document.frames[i].document.styleSheets.length;
			//alert(" x = " + x);
			
   			for(var z=0;z<x;z++)
			{
				//alert(" i = " + i + "  x = " + x + " z = " + z);
				if(z!=whichSheet)
	  			{
        			document.frames[i].document.styleSheets[z].disabled=true;
					//alert("disabled " + z);
      			}
				else
	  			{
        			document.frames[i].document.styleSheets[z].disabled=false;
					//alert("NOT disabled " + z);
      			}
			}
		}
	}
	

}