Knowledge Base |
Important! All new questions are usually answered within the next business day.
Drop Down (Tree) Menu V3
(views: 4585)
Drop Down Menu V3 and Drop Down Tree Menu V3 are xml flash accordion menus featuring customized states, customized transitions and tweens. Here are all known issues for Drop Down Menu V3 and Drop Down Tree Menu V3, they should be similar, since basically it is the same component. If you have any questions that you think we should discuss here please let us know.
Call JavaScript from XML
(2007-07-06 - views: 4127)
Q: How can i call JavaScript function from XML?
A: Nothing more simple. You have to place your JavaScript code in url param in xml like this:
<item title="new Item" url="javascript:yourFunction('This alert is from XML')" target="_self">
In order to make this example functionable you have to set target param to indicate where is your JavaScript function is located. If you have your target = "_blank" it will search for your JavaScript function in a blank HTML page.User Comments
dispatch a click event
Yes, it is possible to dispatch a click event for the AS2 component. Just use the dispatchEvent method of the component to dispatch the desired event and you can also pass any parameters you like through the event object:
myMenu.dispatchEvent( { target:myMenu, type:"onRelease", item:myMenu.items[0], anotherParam:"value" } );
The previous example triggers an "onRelease" event on one of the menu items and also passes along a new parameter to the event handler function called "anotherParam".
posted by negush on 2008-05-12
Yes, it is possible to dispatch a click event for the AS2 component. Just use the dispatchEvent method of the component to dispatch the desired event and you can also pass any parameters you like through the event object:
myMenu.dispatchEvent( { target:myMenu, type:"onRelease", item:myMenu.items[0], anotherParam:"value" } );
The previous example triggers an "onRelease" event on one of the menu items and also passes along a new parameter to the event handler function called "anotherParam".
Login to post your comment
Other questions in this item:
Drop over HTML content Open menu item pages into target - "_self" Initiate Drop Down Tree Menu V3 through ActionScript Item description from XML Disable-Enable Drop Down (Tree) Menu Navigate through scenes Displaying the submenu horizontally instead of vertical Hand cursor Adding a checkbox to a menu Referencing item's textfield in Drop Down (Tree) Menu V3 Centering the titles on the Drop Down (Tree) Menu V3 Load movies on item select Go to different frames by pressing a menu item Changing Design Autoexpand on start Different text formats and anti alias Adding a separating gap between menu items setXML() generates error message Open menu items upwardsMenu |
|
|


Is it possible to dispatch a click event for a specific item from a movie clip?