W
Weston C
I'm wondering if it's possible to add a method to the Node and/or
Element objects (so they'd subsequently be available to any
node/element). I'd assume you could just do something like:
n.myNewMethod = function myNewMethod;
where n is any Node -- but the fact that Nodes and Elements are
explicitly definied as interfaces rather than actual objects in the DOM
standard makes me wary. Javascript/ECMAscript, iirc, however, uses a
prototype object-oriented model that doesn't have interfaces, right?
Thanks,
Weston
~==~
http://weston.canncentral.org/
Taking Pictures During Dreams
weston8[at]cann8central.org
(remove eights to email me)
Element objects (so they'd subsequently be available to any
node/element). I'd assume you could just do something like:
n.myNewMethod = function myNewMethod;
where n is any Node -- but the fact that Nodes and Elements are
explicitly definied as interfaces rather than actual objects in the DOM
standard makes me wary. Javascript/ECMAscript, iirc, however, uses a
prototype object-oriented model that doesn't have interfaces, right?
Thanks,
Weston
~==~
http://weston.canncentral.org/
Taking Pictures During Dreams
weston8[at]cann8central.org
(remove eights to email me)