R
Richard Trahan
I have the following line of code:
var newopt = document.createElement("option");
I addChild this to a select list node and it works fine.
I want to attach an object reference to newopt, but the system doesn't
allow me to do this:
newopt.createAttribute("graph")
nor does it allow this:
newopt.setAttribute("graph",new MyObject)
I can't find any mention in the DOM that attributes cannot be added to
element nodes.
My question, then, is: how can I attach an object reference to an option
node?
var newopt = document.createElement("option");
I addChild this to a select list node and it works fine.
I want to attach an object reference to newopt, but the system doesn't
allow me to do this:
newopt.createAttribute("graph")
nor does it allow this:
newopt.setAttribute("graph",new MyObject)
I can't find any mention in the DOM that attributes cannot be added to
element nodes.
My question, then, is: how can I attach an object reference to an option
node?