


function positionScreenElements(){		

    var winH=findBrowserSize().height
    var winW=findBrowserSize().width

document.getElementById("PageBackground").style.left = (winW-1000)/2 +"px";
document.getElementById("PageBackground").style.top = (winH-550)/2 +"px";
document.getElementById("PageBackground2").style.top = (winH-550)/2 +"px";
document.getElementById("PageBackground2").style.left = (winW-1010)/2 +"px";

document.getElementById("content").style.left = ((winW-1000)/2)+71 +"px";
document.getElementById("content").style.top = ((winH-550)/2)+80 +"px";

try{document.getElementById("contentNavFooter").style.bottom = ((winH-550)/2)+83 +"px";}
catch(err){}

//document.getElementById("content").style.width = ((winW-1000)/2)+471 +"px";

if (navigator.appName.indexOf("Microsoft")!=-1) {
    }
//        document.getElementById("content").style.top = ((winH-550)/2)+28 +"px";
//        document.getElementById("content").style.width = ((winW-1000)/2)+385 +"px";
}





// ============================================================= //

function findBrowserSize(type){
// determine browser size
var winW, winH
if (parseInt(navigator.appVersion)>3) {
 if (navigator.appName=="Netscape") {
  winW = window.innerWidth;
  winH = window.innerHeight;
 }
 if (navigator.appName.indexOf("Microsoft")!=-1) {
  winW = document.body.offsetWidth;
  winH = document.body.offsetHeight;
 }
}
if(winW==null){winW=800;winH=450}

return{width: winW, height: winH}

}


function createCookie(name, value, days)
{
  if (days) {
    var date = new Date();
    date.setTime(date.getTime()+(days*24*60*60*1000));
    var expires = "; expires="+date.toGMTString();
    }
  else var expires = "";
  document.cookie = name+"="+value+expires+"; path=/";
}

function readCookie(name)
{
  var ca = document.cookie.split(';');
  var nameEQ = name + "=";
  for(var i=0; i < ca.length; i++) {
    var c = ca[i];
    while (c.charAt(0)==' ') c = c.substring(1, c.length); //delete spaces
    if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length, c.length);
    }
  return null;
}



