if (document.getElementsByTagName && document.getElementById && document.createElement && document.createTextNode) {
     
   var util = {
   
  
          
   // reference to paragraph where insertion occurs
   theList : document.getElementsByTagName("ul")[0],
            
  

  
 configEvents : function() {
      if (document.addEventListener) {
        this.addEvent = function(el, type, func, capture) { el.addEventListener(type, func, capture); };
        this.stopBubble = function(evt) { evt.stopPropagation(); };
        this.stopDefault = function(evt) { evt.preventDefault(); };
        this.findTarget = function(evt, targetNode, container) {
         var currentNode = evt.target;
         while (currentNode && currentNode !== container) {
          if (currentNode.nodeName.toLowerCase() === targetNode) { return currentNode; break; }
          else { currentNode = currentNode.parentNode; }
         };
         return false;
        };
      }
      else if (document.attachEvent) {
       this.addEvent = function(el, type, func) { el["e" + type + func] = func; el[type + func] = function() { el["e" + type + func] (window.event); }; el.attachEvent("on" + type, el[type + func]); };
       this.stopBubble = function(evt) { evt.cancelBubble = true; };
       this.stopDefault = function(evt) { evt.returnValue = false; };
       this.findTarget = function(evt, targetNode, container) { var currentNode = evt.srcElement; 
        while (currentNode && currentNode !== container) {
         if (currentNode.nodeName.toLowerCase() === targetNode) { return currentNode; break; }
         else { currentNode = currentNode.parentNode; }
        };
        return false;
       };
      }
    },
  
 displayOn : function(evt) {
  
    // pinpoint the list item
    var theListItem = util.findTarget(evt, 'li', this);
    
    //pinpoint the anchor
    var theAnchor = util.findTarget(evt, 'a', this);
    
    //stop function if neither element node id found
    if (!theListItem && !theAnchor) { return;}
    
    if (theListItem) {
      
      //toggle list item classes
      theListItem.className = 'highlight';
      }
  },
  
  displayOff : function(evt) {
  
    // pinpoint the list item
    var theListItem = util.findTarget(evt, 'li', this);
    
    //pinpoint the anchor
    var theAnchor = util.findTarget(evt, 'a', this);
    
    //stop function if neither element node id found
    if (!theListItem && !theAnchor) { return;}
    
    if (theListItem) {
      
      //toggle list item classes
      theListItem.className = '';
      }
  },
  
  changeColor : function(evt) {
  
    // pinpoint the list item
    var theListItem = util.findTarget(evt, 'li', this);
    
    //pinpoint the anchor
    var theAnchor = util.findTarget(evt, 'a', this);
    
    //stop function if neither element node id found
    if (!theListItem && !theAnchor) { return;}
    
    if (theListItem) {
      
      //toggle list item classes
      theListItem.className = 'highlight';
      }
  },    
  
  
  
  
  
  
init : function() {
             
         // configure event assignment and handling
         this.configEvents();
         this.addEvent(this.theList, "mouseover", this.displayOn, false);
         this.addEvent(this.theList, "mouseout", this.displayOff, false);
         this.addEvent(this.theList, "focus", this.displayOn, true);
         this.addEvent(this.theList, "blur", this.displayOff, true); 
         this.addEvent(this.theList, "focusin", this.displayOn, false);
         this.addEvent(this.theList, "focusout", this.displayOff, false);   
         this.addEvent(this.theList, "keyup", this.changeColor, false);
         this.addEvent(this.theList, "onclick", this.changeColor, false);
           
      }
      
      };
      
      util.init();
   }
