Home >Web Front-end >JS Tutorial >Beautiful imitation flash menu from Blue Classic_JavaScript
<script><br>/* <br>http://lexrus.blueidea.com</font></p> <p><font face="Verdana">This is the function that binds event actions to the menu<br>*/<br>function attachXMenu(objid){<br> var tds=objid.getElementsByTagName('td');<br> for(var i=0;i<tds.length;i ){<BR> with(tds[i]){<BR> onmouseover=function(){<BR> with(this){<BR> filters[0 ].apply();<BR> style.background='#66CCFF'; //This is the background color when the mouse is moved up<BR> style.border='1px solid #ffffff'; //Border<BR> style .color='black'; //Text color<BR> filters[0].play();<BR> }<BR> }<BR> onmouseout=function(){<BR> with(this){<BR> filters[0].apply();<BR> style.background='#336699'; //This is the background color when the mouse leaves <BR> style.border='1px solid #336699'; //Border<BR> style.color='#ffffff'; //Text color<BR> filters[0].play();<BR> }<BR> }<BR> }<BR> }<BR>}<BR> </script>
< td>www.lenvo.cn
Name
Is
LeX
Rus
!!!
<script>attachXMenu(xmenu0); //Execute event action binding at the end of the table above. The xmenu0 here is the id of that table</script>
My Name
Is
LeX
Rus
!!!< ;/td>
<script>attachXMenu(xmenu1);</script>