|
[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Namespace declaration using DOM
Christian Nentwich wrote:
>
>><RootElement xmlns:c="http://pradeepbhat.com">
>><c:name>pradeep</c:name>
>><RootElement>
>>My problem is how to put the xml name space declaration in RootElement.
>>Some one plz help;
>
>
> root.setAttribute("xmlns:c","http://pradeepbhat.com");
>
I don't think this is correct. Namespaces are *not* attributes.
You'll have to create the c:name element using
createElementNS("http://pradeepbhat.com","c:name");
(there may be other possibilities)
J.Pietschmann
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|
|||||||||

Cart








