XML Doubt

webmasterbeta

New Member
My doubt is

i got one xml like
<main>
<block>

<block>
</block>

<block>
<block>
</block>
</block>

</block>
</main>
this means that one block tag can have 0 or many block tags as child.
problem is if i want to get all the block tags comes directly under main tag i ve to use getElementByTagNames() which returns the NodList here the problem is it returs all the tags under main tag and i need only the block tag which is directly under the main tag
what should i do for that
pls help
thank you

saju.m
 
Back
Top