﻿/* Javascript to Hover over list items for IE 6 and below */

function liHover() {
    // Search for all li tags and store them in li_items array.
    var li_items = document.getElementsByTagName("LI");

    // Define mouse over and mouse out functions for each li item that has .lihover class
    for (var ctr = 0; ctr < li_items.length; ctr++) {
        li_items[ctr].onmouseover = function() {
            this.className += "lihover";
        }

        li_items[ctr].onmouseout = function() {
        // Javascript needs to escape the escape character \ in literal strings
        // therefore the reasons for the \\b instead of \b.  The \b escape character
        // will match to a word boundary regardless of white space.
            this.className.replace(new RegExp("lihover\\b"), "");
        }
    }
}

