/*	boxkill2.js
	M G O'Farrell, III
	030202

	JavaScript to kill the focus box
	around text links

	based upon an earlier script, that blew-out
	when it encountered an IMG used as a link.
*/

function focusHandler(e) { 
  if (!e)
    e = window.event;

  if (e.target) // "Netscape"
    obj = e.target;
  else if (e.srcElement) // Micro$oft
    obj = e.srcElement;
  else // oops! no idea what we've got here
    return;

  /* obj can still be something other than type "A".
     if this happens on, say, an IMG, an exception
     occurs. therefore, it's necessary to do nothing
     if capture has occured on an element contained
     within the anchor.
  */
    
  if (obj.tagName != "A")
      return;

  obj.blur();
}

function boxKill() { 
  if (document.links)
    for ( i = 0; i < document.links.length; i++ ) {
      // register our event handler for each link
      document.links[i].onfocus = focusHandler;
    }
}
