var videoWindow = null;

function openVideo( src, width, height ) {
  if (videoWindow) { videoWindow.close() }
  videoWindow = window.open(src,'movie','width='+width+',height='+height+',resizable=no','dependent=yes','scrollbars=no','status=no','menubar=no','directories=no','location=no');
  if (window.focus) { videoWindow.focus() }
  return false;
}

function removeNag() {
  objects = document.getElementsByTagName("object");
  for (var i = 0; i < objects.length; i++) {
    objects[i].outerHTML = objects[i].outerHTML;
  }
}

function add_zoom() {
  var links = document.getElementsByTagName('a');
  var aValue = /lytebox/i;
  var iValue = /img/i;

  for(var i=0; i<links.length; i++) {
    link = links[i];
    oAttribute = link.getAttribute && link.getAttribute('rel');
    if (typeof oAttribute == "string" && oAttribute.length > 0) {
      if (aValue.test(oAttribute)) {
        if (iValue.test(link.innerHTML)) {
          link.innerHTML += '<span class="zoom"></span>';
        }
      }
    }
  }

  return;
}