Rank: Newbie Groups: Member
Joined: 10/12/2007 Posts: 8
|
How do I identify that a particular menu item is selected from a menu?
function on_context_menu_item_click(e, info) {
if(info.getItem(0).selected="true") { var url2 = "someyhing.aspx"; window.open(url2, "_blank"); } if(info.getItem(1).selected="true") { var url3 = "anything.aspx"; window.open(url3, "_blank"); }
}
But this code executes only the first if loop
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,217
|
You shouldn't use ".selected". You should use ".getSelected()". You can check the client side API reference for what's available and what's not.
|