• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: way to get XML attributes
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: way to get XML attributes


  • Subject: Re: way to get XML attributes
  • From: LE STANG Jean-Baptiste <email@hidden>
  • Date: Tue, 11 Mar 2003 23:04:37 +0100

You might also try the XSLT osax from Late Night Software, you'll have to learn a little bit about xslt (a good site for learning XSLT is www.zvon.org), but when you master XSLT, you can do lot of manipulation on XML documents (and not only on xml documents).



JB


Le mardi, 11 mars 2003, ` 14:06 Europe/Paris, has a icrit :

Darwin Zins wrote:

I am using the XML tools from Late Night Software to parse an xml file.
The problem I am having is that the data in the xml file is all stored
as attributes and each element may have a different number of
attributes.

Your attribute names are known, so concatenate the attribute record like so:

set attribRec to attribRec & {|LastName|:missing value,
[NO-BREAK]|FirstName|:missing value, |BusinessPhone|:missing value,
[NO-BREAK]|BusinessFax|:missing value, [your other properties here]}

That'll give you a record containing all possible properties, and you can test each by name to see if its value is a string (XML attribute exists) or 'missing value' (no XML attribute).

has
--
http://www.barple.pwp.blueyonder.co.uk -- The Little Page of AppleScripts
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: way to get XML attributes (From: has <email@hidden>)

  • Prev by Date: Secure Delete Droplet (final)
  • Next by Date: Re: Determining item number matching "x" in a list
  • Previous by thread: Re: Procedure Problem
  • Next by thread: QXP5 and Layers
  • Index(es):
    • Date
    • Thread