Satimage: non-greedy regexp matching?
Satimage: non-greedy regexp matching?
- Subject: Satimage: non-greedy regexp matching?
- From: Wim Melis <email@hidden>
- Date: Mon, 20 Dec 2004 19:38:37 +0100
I'm trying to get a regexp match using the Satimage addition, looking for
the complete <A...>...</A> blocks in an HTML page.
Unfortunately the match is always 'greedy', ie:
set theHTML to
"<a href=\"file1.html\">link1</a> test <a href=\"file2.html\">link2</a>"
set x to find text "<a href=.*</a>" in theHTML with regexp, string result
and all occurrences
This results in one match, being the entire string, not in two separate
matches. The 'link' part in the string could also be an image, so [^<]*
instead of .* won't work.
(And the usual regex .*? construct doesn't seem to be supported.)
Is this possible somehow, or does the Satimage addition only support greedy
matches?
Thanks,
Wim
--
email (home): email@hidden
email (office): email@hidden
http://www.noorderlicht.com * Noorderlicht photofestival
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden