W3C home > Mailing lists > Public > www-dom@w3.org > October to December 2002

FAQ: Worth adding "avoid createElement()/createAttribute()"?

From: Joseph Kesselman <keshlam@us.ibm.com>
Date: Thu, 17 Oct 2002 19:39:32 -0400
To: WWW DOM <www-dom@w3.org>
Message-ID: <OF977A3689.6A5C2D57-ON85256C55.008143C3-85256C55.0082093D@us.ibm.com>

I am still seeing people confused by the fact that createElement("foo") 
and createElementNS(null,"foo") are not interchangable. Ditto for 
attributes.

I can point them to DOM 2.0 Core 1.1.8, but it would be good to have an 
official practical-advice summary. "Yes, they're different and not really 
ineroperable. Unless you are writing a pure DOM 1.0 application, don't use 
the non-namespace-aware version of these calls." 

Or something along those lines, easy to find and short enough to absorb at 
a glance.

(A few folks have also grumbled "why isn't that advice in the Javadoc?". 
Might be worth considering for future releases.)

______________________________________
Joe Kesselman  / IBM Research
Received on Thursday, 17 October 2002 19:40:11 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 22 June 2012 06:13:56 GMT