menu_status = new Array(); 
function showHide(theid){
    if (document.getElementById) {
      var switch_id = document.getElementById(theid);
      if(menu_status[theid] != 'show') {
          switch_id.className = 'show';
          menu_status[theid] = 'show';
       }else{
          switch_id.className = 'hide';
          menu_status[theid] = 'hide';
       }
   }
   movefooter();
}

// MSIE position fixed fix
  var footerinit=1;
  function movefooter() {

     var foot = document.getElementById("footer");
     foot.style.position="absolute";

     var newtop = document.body.scrollTop + document.body.clientHeight - foot.offsetHeight;
     var mintop = document.getElementById("fcontrol").offsetTop;

     if(newtop<mintop) newtop = mintop;
     if(foot.style.top==(newtop + "px")) return;

     foot.style.top = newtop + "px";
     foot.style.width ="778";
     foot.style.zindex=-1;

     if(footerinit)
     {
        window.onscroll= movefooter;
        window.onresize= movefooter;
        footerinit=0;
     }
  }
  window.onload = movefooter;

