If your data is that consistent and all you need is to transfer it to
arrays, then why do you need xpath, you could write your own parser,
using while loops, to do this in very little time.
I'm not an experrt, but it seems to me that xpath is more useful for
dynamic access to the xml. Is that not correct?
If I am correct, an interesting question is; what is more efficient,
transferring to arrays and using the arrays, or dynamically accessing
the xml directly?

On 6/5/06, Sajid Saiyed <[EMAIL PROTECTED]> wrote:
Hi,
I have an XML like this:

<root>
        <totalLayers>
                <number>5</number>
        </totalLayers>
        <LayerOne>
                <asset>
                 <name>somename0.bmp</name>
                <width>20</width>
                <height>10</height>
                <xPos>50</xPos>
                <yPos>30</yPos>
                </asset>
                <asset>
                 <name>somename1.bmp</name>
                <width>20</width>
                <height>10</height>
                <xPos>50</xPos>
                <yPos>30</yPos>
                </asset>
        </LayerOne>
        <Layertwo>
                <asset>
                 <name>somename2.bmp</name>
                <width>20</width>
                <height>10</height>
                <xPos>50</xPos>
                <yPos>30</yPos>
                </asset>
        </LayerTwo>
</root>

I want to use XPATH or something similar to create dynamic
arrays/string and store values respectivele like this:

String:
totalLayers = "5";

LayerOne and LayerTwo will be a multidimentional array"

LayerOne[[asset[name,width,height,xpos,ypos]][asset[name,width,height,xpos,ypos]]...]
LayerTwo[[asset[name,width,height,xpos,ypos]][asset[name,width,height,xpos,ypos]]...]
etc...

Any hint or suggestion...?
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com



--
Weldon MacDonald
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to