function highlightMenu(itmName) {
 var nav=document.getElementById("nav");
 if(nav==null) { return; }
 var elm=nav.getElementsByTagName("A");
 for(var i=0,li=elm.length;i<li;i++) {
  if(elm[i].innerHTML==itmName) { elm[i].className+=((elm[i].className.length)?' ':'')+"sel";elm[i].parentNode.className+=((elm[i].parentNode.className.length)?' ':'')+"sel"; }
 }
}
function addOnLoad2(sObj, func) {
 if(sObj && sObj.document && sObj.document.readyState && sObj.document.readyState=="complete") { func();return; }
 if(sObj.addEventListener) {
  sObj.addEventListener("load", func, false);
 } else if (sObj.attachEvent) {
  sObj.attachEvent("onload", func);
 } else if (document.getElementById) {
  if(typeof sObj.onload!='function') {
   sObj.onload=func;
  } else {
   sObj.oldonload=sObj.onload;
   sObj.onload=function() { sObj.oldonload();func(); }
  }
 }
}
function addOnLoad(func) {
 addOnLoad2(window, func);
}
function addOnDOMready(func) {
 if(document.addEventListener) {
  document.addEventListener("DOMContentLoaded", func, false);
 } else if(document.attachEvent) {
  document.attachEvent('onreadystatechange',function() { if(document.readyState=='complete') { func(); } });
 } else {
  if(typeof document.onreadystatechange!='function') {
   document.onreadystatechange=function() { if(this.readyState=='complete') { func(); } };
  } else {
   addOnLoad(func);
  }
 }
}

function headerDropShadowIE() {

 for(var i=1;i<=2;i++) {
  var elm=document.getElementsByTagName('h'+i);
  for(var j=0;j<elm.length;j++) {
if(!(elm[j].nextSibling && elm[j].nextSibling.className && (elm[j].nextSibling.className.substring(0,4)=='h1sh' || elm[j].nextSibling.className.substring(0,4)=='h2sh' || elm[j].nextSibling.className.substring(0,4)=='h2shy' || elm[j].nextSibling.className.substring(0,4)=='h2sh2'))) {
   if(getRenderedStyle(elm[j],'text-shadow')==null && elm[j].currentStyle && elm[j].currentStyle['text-shadow']!=null) {
    var txtShadow=elm[j].currentStyle['text-shadow'].split(' ');
    if(txtShadow.length==4) {
     if(elm[j].className.indexOf('shadow_added')==-1 && elm[j].className.indexOf('is_the_shadow_added')==-1) {
      elm[j].style.position='relative';
      elm[j].style.zoom='1';
      var newElm=elm[j].cloneNode(true);
      elm[j].className+=((elm[j].className.length)?' ':'')+'shadow_added';
      newElm.className+=((newElm.className.length)?' ':'')+'is_the_shadow_added';
      newElm.style.color=txtShadow[0];
      var newElmChild=newElm.getElementsByTagName('*');
      for(var k=0;k<newElmChild.length;k++) {
       newElmChild[k].style.color=txtShadow[0];
      }
      newElm.style.marginTop=(parseInt(getRenderedStyle(elm[j],'margin-top'))+parseInt(txtShadow[1]))+'px';
      newElm.style.marginBottom=(-parseInt(getRenderedStyle(elm[j],'margin-top'))-elm[j].offsetHeight-parseInt(txtShadow[1]))+'px';
      newElm.style.marginLeft=(parseInt(getRenderedStyle(elm[j],'margin-left'))+parseInt(txtShadow[2]))+'px';
      newElm.style.marginRight=(parseInt(getRenderedStyle(elm[j],'margin-right'))-parseInt(txtShadow[2]))+'px';
      newElm.style.zIndex=getRenderedStyle(elm[j],'z-index')-1;
      elm[j].parentNode.insertBefore(newElm,elm[j]);
     }
    }
   }
}
  }
 }
} addOnDOMready(headerDropShadowIE);

function getRenderedStyle(oElm, strCssRule){
 var strValue = "";
 if(document.defaultView && document.defaultView.getComputedStyle){
  var compStyle = document.defaultView.getComputedStyle(oElm, "");
  if(compStyle != null) { strValue = compStyle.getPropertyValue(strCssRule); }
 } else if(oElm.currentStyle){
  strCssRule = strCssRule.replace(/\-(\w)/g, function (strMatch, p1){
   return p1.toUpperCase();
  });
  strValue = oElm.currentStyle[strCssRule];
 }
 return strValue;
}

