tags:

views:

55

answers:

2

I have a form that I am using innerHTML to view the contents of one div in another div. When the user clicks the button, they should be able to view their template. However I am dragging a tree from an XML file and even though the code runs, I get undefined as an output. Am a newbie at this, so any help would be much appreciated!

Any thoughts?

Thanks!

+3  A: 

you can't use innerHTML property with xml, because it's exist only in HTML DOM. You have to use cloneNode() method instead

shiberz
A: 

node.firstChild.data wont work with tree. It works if you have only textNode inside your element.

shiberz