[Dojo-interest] Re: Popupmenu2
manxomfoe.lists at gmail.com
Tue Jan 23 14:21:09 MST 2007
You can attach a context menu to any node, as long as you have a
reference to that node.
Encapsulate your 100 div nodes inside a div with an ID, and you can
then use this statement to get a reference to all the nodes:
var nodes = dojo.byId("myWrapperId").getElementsByTagName("div")
Then loop thru the nodes and assign your context menu to each one.
On 1/22/07, John W. Ryan <john.w.ryan2000 at gmail.com> wrote:
> Hello Everyone,
> I am dynamically creating a few nodes (about 100) and i need to assign a
> contextmenu to every single one of them. the div containers are not
> dojotype. Is there anyway to make that happen?
> I have studied about bindDomNode method but all the specified examples are
> for different dojo containers. If the solution is to register my divs w.
> Dojo, how would that be possible? I am a Dojo iliterate so I would need an
> example w/ code.
> I will appreciate an answer. Thanks a great deal.
> John W. Ryan
> Dojo FAQ: http://dojo.jot.com/FAQ
> Dojo Book: http://manual.dojotoolkit.org/DojoDotBook
> Dojo-interest at dojotoolkit.org
More information about the Dojo-interest