function smartRollover() {
        if(document.getElementsByTagName) {
            var img = document.getElementsByTagName("img");

            for(var i=0; i < img.length; i++) {
                if(img[i].getAttribute("src").match("_off."))
                {
                    img[i].onmouseover = function() {
                        this.setAttribute("src", this.getAttribute("src").replace("_off.", "_on."));
                    }
                    img[i].onmouseout = function() {
                        this.setAttribute("src", this.getAttribute("src").replace("_on.", "_off."));
                    }
                }
            }
        }
    }

    if(window.addEventListener) {
        window.addEventListener("load", smartRollover, false);
    }
    else if(window.attachEvent) {
        window.attachEvent("onload", smartRollover);
    }



function m_win(url,windowname,width,height) {
 var features="location=no, menubar=no, status=no, scrollbars=no, resizable=yes, toolbar=no";
 if (width) {
  if (window.screen.width > width)
   features+=", left="+(window.screen.width-width)/2;
  else width=window.screen.width;
  features+=", width="+width;
 }
 if (height) {
  if (window.screen.height > height)
   features+=", top="+(window.screen.height-height)/2;
  else height=window.screen.height;
  features+=", height="+height;
 }
 window.open(url,windowname,features);
}

function ticke_win(url,windowname,width,height) {
 var features="location=no, menubar=yes, status=no, scrollbars=no, resizable=yes, toolbar=no";
 if (width) {
  if (window.screen.width > width)
   features+=", left="+(window.screen.width-width)/2;
  else width=window.screen.width;
  features+=", width="+width;
 }
 if (height) {
  if (window.screen.height > height)
   features+=", top="+(window.screen.height-height)/2;
  else height=window.screen.height;
  features+=", height="+height;
 }
 window.open(url,windowname,features);
}


