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 - How to Configure JAXRS and Spring With Annotations -

visual studio - TFS will not accept changes I've made to a Java project -

php - Create image in codeigniter on the fly -