Hmmmm
Let's try again :)
<item id="0006" name="ASSY, SPLIT CLUTCH COVER">
<item id="0001" name="SPLIT CLUTCH COVER">
<item id="0001" name="CLUTCH COVER MACH.">
<item id="0001" name="CLUTCH COVER WELDMENT">
<item id="0001" name="HR PLATE">
<item id="0010" name="PLATE(A572-50)"/>
</item>
<item id="0002" name="TUBING">
<item id="0001" name="15X13-1/2 TUBING C1026"/>
</item>
<item id="0003" name="PLATE">
<item id="0010" name="PLATE(A572-50)"/>
</item>
<item id="0004" name="END TUBE">
<item id="0001" name="PLATE(A572-50)"/>
</item>
<item id="0005" name="END PLATE">
<item id="0001" name="PLATE(A572-50)"/>
</item>
</item>
</item>
</item>
I removed some of the extra attributes to get it to format
correctly. Hopefully this works.
--- In [email protected], "Tracy Spratt" <[EMAIL PROTECTED]>
wrote:
>
> Is there anyway to post that xml so it stays formatted? I really
do not
> like that part of the new yahoo groups.
>
> Tracy
>
>
>
> ________________________________
>
> From: [email protected]
[mailto:[EMAIL PROTECTED] On
> Behalf Of wayneposner
> Sent: Wednesday, June 21, 2006 2:44 PM
> To: [email protected]
> Subject: [flexcoders] Building "flat" data object based on XML
file with
> complicated structure
>
>
>
> Howdy all!!
>
> Take the following blurb of XML:
>
> <item id="0006" qty="2.000" uom="EA" matnr="347565"
> bismt="DBT347565" name="ASSY, SPLIT CLUTCH COVER" hasBom="X"
> path="pdf/347565.pdf" image="pdf/thumbnails/347565.jpg">
> <item id="0001" qty="1.000" uom="EA" matnr="347564"
> bismt="DBT347564" name="SPLIT CLUTCH COVER" hasBom="X"
> path="pdf/347564.pdf" image="pdf/thumbnails/347564.jpg">
> <item id="0001" qty="1.000" uom="EA" matnr="313551"
> bismt="DBT313551" name="CLUTCH COVER MACH." hasBom="X"
> path="pdf/313551.pdf" image="pdf/thumbnails/313551.jpg">
> <item id="0001" qty="1.000" uom="EA" matnr="313552"
> bismt="DBT313552" name="CLUTCH COVER WELDMENT" hasBom="X"
> path="pdf/313552.pdf" image="pdf/thumbnails/313552.jpg">
> <item id="0001" qty="1.000" uom="EA" matnr="169902"
> bismt="J-548F613MK002" name="HR PLATE" hasBom="X"
> path="pdf/169902.pdf" image="pdf/thumbnails/169902.jpg">
> <item id="0010" qty="2.000" uom="FT2" matnr="131877"
> bismt="0000 008 302 72 61" name="PLATE(A572-50)1.00""
> hasBom=""/>
> </item>
> <item id="0002" qty="1.000" uom="EA" matnr="313554"
> bismt="DBT313554" name="TUBING" hasBom="X" path="pdf/313554.pdf"
> image="pdf/thumbnails/313554.jpg">
> <item id="0001" qty="0.660" uom="IN" matnr="169626"
> bismt="J-294-07-026" name="15X13-1/2 TUBING C1026" hasBom=""/>
> </item>
> <item id="0003" qty="1.000" uom="EA" matnr="169903"
> bismt="J-548F613MK003" name="PLATE" hasBom="X"
path="pdf/169903.pdf"
> image="pdf/thumbnails/169903.jpg">
> <item id="0010" qty="1.200" uom="FT2" matnr="131872"
> bismt="0000 008 302 72 55" name="PLATE(A572-50).50""
hasBom=""/>
> </item>
> <item id="0004" qty="1.000" uom="EA" matnr="313556"
> bismt="DBT313556" name="END TUBE" hasBom="X" path="pdf/313556.pdf"
> image="pdf/thumbnails/313556.jpg">
> <item id="0001" qty="0.800" uom="FT2" matnr="131883"
> bismt="0000 008 302 72 67" name="PLATE(A572-50)1.50""
> hasBom=""/>
> </item>
> <item id="0005" qty="1.000" uom="EA" matnr="313557"
> bismt="DBT313557" name="END PLATE" hasBom="X"
path="pdf/313557.pdf"
> image="pdf/thumbnails/313557.jpg">
> <item id="0001" qty="0.600" uom="FT2" matnr="131872"
> bismt="0000 008 302 72 55" name="PLATE(A572-50).50""
hasBom=""/>
> </item>
> </item>
> </item>
> </item>
>
> I've been trying to build an array of objects of it and flatten it
> down so that each item node would simply be an entry in the array.
> If I use a recursive function, I only get the deepest node
> returned. If I use the "for each (var prop:XML in myXML.item)"
loop
> I only get the children of the root and not the grandchildren. How
> do I get EVERY node???
>
> Thanks!
>
> Wayne
>
------------------------ Yahoo! Groups Sponsor --------------------~-->
Great things are happening at Yahoo! Groups. See the new email design.
http://us.click.yahoo.com/TISQkA/hOaOAA/yQLSAA/nhFolB/TM
--------------------------------------------------------------------~->
--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/