Here it goes...
well, hope that helps!!Code:<script LANGUAGE="JavaScript"> var img1 = new Image(); img1.src = "images/plus.gif"; var img2 = new Image(); img2.src = "images/minus.gif"; function doOutline() { var srcId, srcElement, targetElement; srcElement = window.event.srcElement; //the menu element that was pressed if (srcElement.className.toUpperCase() == "LEVEL1" || srcElement.className.toUpperCase() == "FAQ") { srcID = srcElement.id.substr(0, srcElement.id.length-1); //the last number targetElement = document.all(srcID + "s"); //ID="OUT0s" for <div style="blah"> srcElement = document.all(srcID + "i"); //ID="OUT0i" for images if (targetElement.style.display == "none") { targetElement.style.display = ""; if (srcElement.className == "LEVEL1") srcElement.src = img2.src; } else { targetElement.style.display = "none"; if (srcElement.className == "LEVEL1") srcElement.src = img1.src; } } } document.onclick = doOutline; //do outline when it gets clicked </script>
know that it uses css styles to 'hide'/'show' the menus...




:MoMad:
Reply With Quote