//function for scrollIntoView netscape
function HTMLElement_getPageCoords () {
  var coords = {x: 0, y: 0};
  var el = this;
  do {
    coords.x += el.offsetLeft;
    coords.y += el.offsetTop;
  }
  while ((el = el.offsetParent));
  return coords;
}

function HTMLElement_scrollIntoView () {
var coords = this.getPageCoords();
window.scrollTo(coords.x, coords.y);
}

HTMLElement.prototype.getPageCoords = HTMLElement_getPageCoords;
HTMLElement.prototype.scrollIntoView = HTMLElement_scrollIntoView;
