• 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: ML text entity parsing code?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ML text entity parsing code?


  • Subject: Re: ML text entity parsing code?
  • From: "Marc K. Myers" <email@hidden>
  • Date: Sun, 04 Aug 2002 18:21:04 -0400
  • Organization: [very little]

> Date: Sun, 4 Aug 2002 18:21:25 +0200
> From: Brennan <email@hidden>
> Subject: ML text entity parsing code?
> To: applescript-users <email@hidden>
>
> Hi there,
>
> I have a script which converts html to plain text in a very rough way - it strips all tags, except for <BR> and <P> which are converted to linebreaks. All well and good, and quite adequate for my needs but without one small finishing touch.
>
> What's missing is some code for parsing standard ML text entities such as &nbsp; and all that, which I can easily manage to do, but before I reinvent the wheel I'm asking here to see if anyone has got some code to do this anywhere about which I can pilfer.

I use Tex-Edit Plus's "replace" command to replace all identifiable
entities in the text with their preferred representations. Then I use
"replace" with a wildcard to turn all occurrences of characters between
angle brackets (including the brackets) to a single null character. TE+
is thoroughly scriptable and very flexible. The HTML parsing scripts
tend to be quite short.

Marc K. Myers <email@hidden>
http://AppleScriptsToGo.com
4020 W.220th St.
Fairview Park, OH 44126
(440) 331-1074

[8/4/02 6:19:58 PM]
_______________________________________________
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.

  • Prev by Date: Re: OT: Eskimo words for snow (Re: what's a "froplet"?)
  • Next by Date: Re: Eudora Reply-to Mk II
  • Previous by thread: Re: Eudora Reply-to Mk II
  • Next by thread: Was: "+" and "-" are numbers. IS: URL parsing
  • Index(es):
    • Date
    • Thread