<!--     

     // Mouseover effect on left hand menu
function addOnloadEvent(fnc){
  if ( typeof window.addEventListener != "undefined" )
    window.addEventListener( "load", fnc, false );
  else if ( typeof window.attachEvent != "undefined" ) {
    window.attachEvent( "onload", fnc );
  }
  else {
    if ( window.onload != null ) {
      var oldOnload = window.onload;
      window.onload = function ( e ) {
        oldOnload( e );
        window[fnc]();
      };
    }
    else
      window.onload = fnc;
  }
}

addOnloadEvent(function() {
  var items = document.getElementsByTagName("div");
  for (var i = 0; i < items.length; i++) {
    if (items[i].className=="menuoff") {
      items[i].onmouseover = function() {
        this.style.backgroundColor = '#7C6D60';
        this.style.backgroundImage = "url" + "('/assets/menu_shadow.jpg')";
      };
      items[i].onmouseout = function() {
        this.style.backgroundColor = '';
        this.style.backgroundImage = "url" + "('/assets/menu_line.gif')";
      };
    }
  }
} );

     // Stylesheet change

function setCookie(name, value) {
expires = new Date();
expires.setYear(expires.getYear() + 1900 + 2);
var curCookie = name + "=" + escape(value) + ((expires) ? "; expires=" + expires.toGMTString() : "" )+ "; path=/";
document.cookie = curCookie;
}

function getCookie(name) {
var prefix = name + "=";
var nullstring = "";
var cookieStartIndex = document.cookie.indexOf(prefix);
if (cookieStartIndex == -1)
return nullstring;
var cookieEndIndex = document.cookie.indexOf(";", cookieStartIndex + prefix.length);
if (cookieEndIndex == -1)
cookieEndIndex = document.cookie.length;
return unescape(document.cookie.substring(cookieStartIndex + prefix.length, cookieEndIndex));
}

var whichskin = getCookie("skinthesite");
if (whichskin == "Default") {
document.write('<link rel="stylesheet" href="/assets/style.css" type="text/css" media="screen" title="Default">')
} else if (whichskin == "Larger") {
document.write('<link rel="stylesheet" href="/assets/style_larger.css" type="text/css" media="screen" title="Larger">')
} else {
document.write('<link rel="stylesheet" href="/assets/style.css" type="text/css" media="screen" title="Default">')
}

// function for changing stylesheets using document.styleSheets
function setStyleSheet(theme){
	setCookie("skinthesite",theme);
	for ( i = 0; i < document.styleSheets.length; i++ ) {
		if ( document.styleSheets[i].title ) {
			document.styleSheets[i].disabled = true;
		if ( document.styleSheets[i].title == theme )
              document.styleSheets[i].disabled = false;
		}
	}
	window.location.reload(false);
}

     // Email pop-up window - English

   function popupsendeng(title){
    var docurl = document.location.href;
    var sendto = "/english/sendfriend/index.php?docurl="+docurl+"&section="+sectiontitle;
    var mywin = window.open(sendto,'sendtofriend','width=500,height=514, directories=no,location=no,menubar=no,scrollbars=yes, status=no,toolbar=no,resizable=yes');
    mywin.focus();
    window.name = "main";
   }


     // Email pop-up window - French

   function popupsendfr(title){
    var docurl = document.location.href;
    var sendto = "/francais/sendfriend/index.php?docurl="+docurl+"&section="+sectiontitle;
    var mywin = window.open(sendto,'sendtofriend','width=500,height=550, directories=no,location=no,menubar=no,scrollbars=yes, status=no,toolbar=no,resizable=yes');
    mywin.focus();
    window.name = "main";
   }


     // quiz pop-up windows

function openquizwin(link,name,width,height) {
window.open(link,name,'toolbar=no,location=no,directories=no,status=no,menubar=no,resizable=yes,copyhistory=yes,scrollbars=yes,width='+width+',height='+height);
window.name = "main";
}


     // All other pop-up windows

function openwin(link,name,width,height) {
window.open(link,name,'toolbar=no,location=no,directories=no,status=no,menubar=no,resizable=yes,copyhistory=yes,scrollbars=no,width='+width+',height='+height);
window.name = "main";
}

     // FAQs reveal



function findPosY(obj)
{
  var curtop = 0;
  if (obj.offsetParent) {
    while (obj.offsetParent) {
      curtop += obj.offsetTop
      obj = obj.offsetParent;
    }
  } else if (obj.y)
    curtop += obj.y;
  return curtop;
}

function hidecell(id)
{
  var element = document.getElementById(id);
  element.style.display = "none"
}

function showcell(id)
{
  var element = document.getElementById(id);
  hidecells();
  element.style.display = "block";
}

function setPosT(obj) 
{
  setTimeout(function(){setPos(obj)},100);
}

function setPos(obj)
{ 
  var y = findPosY(obj);
  scrollTo(0,y);
}

function togglecell(id)
{
  var element = document.getElementById(id);
  if (element.style.display == "none"){
    showcell(id)
  } else {
    hidecell(id)
  }
}

function hidecells()
{
  var allCells = document.getElementsByTagName("div")
  for (var k=0;k<allCells.length;k++) { 
    var cell = allCells[k];
    if(cell.className == "faqhide") {
      cell.style.display = "none" 
    } 
  } 
}


   // -->

