1
0
This repository has been archived on 2021-04-26. You can view files and clone it, but cannot push or open issues or pull requests.
gallery3-contrib/themes/greydragon/js/menus.js
2009-11-30 08:16:33 -08:00

15 lines
556 B
JavaScript

// Javascript originally by Patrick Griffiths and Dan Webb.
// http://htmldog.com/articles/suckerfish/dropdowns/
sfHover = function() {
var sfEls = document.getElementById("gSiteMenu").getElementsByTagName("ul")[0].getElementsByTagName("li");
if (!sfEls) { return; }
for (var i=0; i<sfEls.length; i++) {
sfEls[i].onmouseover=function() { this.className+=" hover"; }
sfEls[i].onmouseout=function() { this.className=this.className.replace(new RegExp(" hover\\b"), ""); }
}
}
if (window.attachEvent) window.attachEvent("onload", sfHover);