I have a menu that is displayed when a user hovers over an anchor tag with a certain class. The same menu is always displayed, but the anchor tags have a different "accNum" attribute. I want to get the value of the accNum attribute from the "parent" element that displayed the menu and append it to the click event of one of the menu items. Something like;
<a href="#" class="actionLink" onmouseover="$('ActionsMenu').style('display','block');" accNum="11111">Actions</a>
<a href="#" class="actionLink" onmouseover="$('ActionsMenu').style('display','block');" accNum="22222">Actions</a>
<a href="#" class="actionLink" onmouseover="$('ActionsMenu').style('display','block');" accNum="33333">Actions</a>
<div id="ActionsMenu" style="display:none;">
<a href="#" id="showAccountValues">Show Account</a>
</div>
Whichever 'ActionLink' is the one hovered over to display the menu, i want to take that AccNum value and create the onClick event of "ShowAccountValues" something like
onClick="showAccountValues('AccNum value of parent');"
any help would be great. Also, I assume I have to bind this to the document.ready() function for 'ActionLink' which makes sense, but i figured if i could get any of it through this that would be great. Thank you