J
JYOUNG79
Just curious if there's any python xml parsing tools built into the Mac (OS 10.4.10 Tiger)? If so,
could anyone
share some simple code (or maybe point me to a web-site) of how to parse xml data from a
file? For example, if I
had a file that contained this:
<colors>
<color base="DeviceGray" />
<color alt="DeviceCMYK" base="Separation">Black</color>
<color alt="Lab" base="Separation">Light Blue</color>
<color alt="ICCBased" base="Separation">Green</color>
</colors>
I'd want to look in the 'colors' xml element, then look at each 'color' xml element inside and
pull any that have
values (which would be Black, Light Blue and Green). I'd like to know how to pull 'attributes'
too.
Thanks very much for your help.
Jay
could anyone
share some simple code (or maybe point me to a web-site) of how to parse xml data from a
file? For example, if I
had a file that contained this:
<colors>
<color base="DeviceGray" />
<color alt="DeviceCMYK" base="Separation">Black</color>
<color alt="Lab" base="Separation">Light Blue</color>
<color alt="ICCBased" base="Separation">Green</color>
</colors>
I'd want to look in the 'colors' xml element, then look at each 'color' xml element inside and
pull any that have
values (which would be Black, Light Blue and Green). I'd like to know how to pull 'attributes'
too.
Thanks very much for your help.
Jay