id in Xml DOM

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
sarris
Forum Contributor
Posts: 137
Joined: Mon Dec 04, 2006 2:44 pm

id in Xml DOM

Post by sarris »

Hi there.
How can i use the getElementsbyId method? Actually what i need to know is how to specify the id of the elements in the xml document?
Add an attribute "id" = 3 for example??

Moreover how do i get the data of a tag?
what i do is for

Code: Select all

var X = root.getElementsByTagName("Territory")[0].data;
to get the first node for example but it doesnt give any data on the X variable.

Thanks
Post Reply