// Put your custom scripts here
function montreCal(id) {
  var dom = (document.getElementById)? true:false;   //DOM

  for (var i = 1; i<=10; i++) {
    cacheItCal('ssCat'+i);
  }
  if (dom) {
  	if (document.getElementById(id)) {
  		document.getElementById(id).style.paddingTop=document.getElementById(id+"TD").offsetHeight+"px";
  		document.getElementById(id+"TD").className="MenuOn";
  		document.getElementById(id).style.left=document.getElementById(id+"TD").offsetLeft+"px";
  		document.getElementById(id).style.top=document.getElementById(id+"TD").offsetTop+"px";
  		document.getElementById(id).style.width=document.getElementById(id+"TD").offsetWidth+"px";
  		document.getElementById(id).style.visibility="visible";
  	}
	} else {
    if (document.all[id]) {
  		document.all[id].style.paddingTop=document.all[id+"TD"].offsetHeight+"px";
  		document.all[id+"TD"].className="MenuOn";
  		document.all[id].style.left=document.all[id+"TD"].offsetLeft+"px";
  		document.all[id].style.top=document.all[id+"TD"].offsetTop+"px";
  		document.all[id].style.width=document.all[id+"TD"].offsetWidth+"px";
  		document.all[id].style.visibility="visible";
  	}
  }
}

function cacheItCal(id) {
  var dom = (document.getElementById)? true:false;   //DOM

  if (dom) {
  	if (document.getElementById(id)) {
  		document.getElementById(id).style.visibility="hidden";
  		document.getElementById(id+"TD").className="";
  	}
	} else {
	  if (document.all[id]) {
		  document.all[id].style.visibility="hidden";
		  document.all[id+"TD"].className="";
	  }
  }
}

function hilightItem(elt,num) {
	var cell=elt.parentNode;
	switch(num) {
		case 1:
			cell.className="itemCellon";
		break;
		
		case 0:
			cell.className="itemCelloff";
		break;
	}
	
}
