liferay - AlloyUI - difference between node.attr("id") and node.getAttribute("id") -


in aui, difference between

node.attr("id") 

and

node.getattribute("id") 

where node object of type node.

the documentation on getattribute says "allows getting attributes on dom nodes, normalizing in cases." don't understand normalizing means, , in case applied.

thanks, alain

node.attr both getter , setter.

if pass second argument attr, set value of attribute (the first argument).

node.getattribute getter.

node.getattribute normalizes value ie , ie < 8. without falling in many details, means may pass w3c standard attribute , work on browsers.

hope helps!


Comments

Popular posts from this blog

java - JavaFX 2 slider labelFormatter not being used -

Detect support for Shoutcast ICY MP3 without navigator.userAgent in Firefox? -

web - SVG not rendering properly in Firefox -