﻿startList = function() {
    if (document.all && document.getElementById) {
        navRoot = document.getElementById("ul_nav");
        for (i = 0; i < navRoot.childNodes.length; i++) {

            var node = navRoot.childNodes[i];

            if (node.nodeName == "LI") {

                node.onmouseover = function() {
                    this.className += " over";
                }
                node.onmouseout = function() {
                    this.className = this.className.replace(" over", "");
                }

                for (n = 0; n < node.childNodes.length; n++) {

                    subnode = node.childNodes[n];

                    if (subnode.nodeName == "UL") {

                        for (s = 0; s < subnode.childNodes.length; s++) {

                            subnode2 = subnode.childNodes[s];

                            if (subnode2.nodeName == "LI") {

                                subnode2.onmouseover = function() {
                                    this.className += " over2";
                                }
                                subnode2.onmouseout = function() {
                                    this.className = this.className.replace(" over2", "");
                                }

                            }

                        }

                    }

                }


            }



        }

    }
}
window.onload = startList;

