//Written By Luis Lopez - Kannary for Elemental Productions. 2008

// JavaScript Document
function popupWindow(url) {
  window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=yes,copyhistory=no,width=,height=,screenX=150,screenY=150,top=150,left=150')
}

//Added 2009 for image browser pop up


function PopupPic(sPicURL) { 
	window.open( "viewer.html?"+sPicURL, "",  "HEIGHT=200,WIDTH=200,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=0,"); 
   } 


// added Google analytics to header





// Added 2009 - Resizing of FLash embed. Out of function to set in swfobject.


var flashW;
var flashY;

if (screen.width<=1024)
{
flashW = 770;
flashY = 580;
} 
else if ((screen.width>1024) && (screen.width<=1280))
{
flashW = 850;
flashY = 640;
} 
else if ((screen.width>1280) && (screen.width<=1680))
{
flashW = 1000;
flashY = 753;
} 
else if (screen.width>1680)
{
flashW = 1150;
flashY = 866;
} 

// Centering WIndow
//MOdify 20098

function DoWindow(){
if (screen.width<=1024)
{
window.moveTo(0,0);
window.resizeTo(screen.width,screen.height);

} 
else if ((screen.width>1024) && (screen.width<=1280))
{
window.moveTo(0,0);
window.resizeTo(screen.width,screen.height);
} 
else if ((screen.width>1280) && (screen.width<=1680))
{
var width_off = ((screen.width-1300)/2);
window.moveTo(width_off,0);
window.resizeTo(1300,900);
} 
else if (screen.width>1680)
{
var width_off = ((screen.width-1700)/2);
window.moveTo(width_off,0);
window.resizeTo(1700,1000);
} 
}