I need to parse a element from a XML file:
<a>
<b>45</b>
<c>67</c>
</a>
<a>
<b>98</b>
<c>89</c>
</a>
So I try to read and put in a html element the first value of b with the next code:
document.getElementById("apDiv3").innerHTML=xmlDoc.getElementsByTagName("b")[0].data;
or
document.getElementById("apDiv3").innerHTML=xmlDoc.getElementsByTagName("b")[0].value;
and I get a undefined message.Where is the problem?