If the headline text doesn't contain any HTML, then you could probably
use:

"<font size=2>[^<]*</font><b></p>"

Replacing the .* with [^<]* matches zero or more of any character _except_
for a <, so that section only matches up to the start of the next tag.

Jim


-----Original Message-----
From: Owens, Howard <[EMAIL PROTECTED]>
To: '[EMAIL PROTECTED]' <[EMAIL PROTECTED]>
Date: Monday, June 19, 2000 5:49 PM
Subject: need a non-greedy RegEx


>
>
>I have a series of headlines on an HTML page.  Some (but not all) of the
>heads have subheads.  I need to strip out the subheads for a list of
>headlines page.
>
>The RegEx I've tried (and I've tried several variations):
>
><cfset newpath=REReplaceNoCase(newpath, "<font size=2>.*</font><b></p>",
>"<br>", "ALL")>
>
>This is too greedy.  It grabs everything from the first subhead on the
page
>to the last (including all intervening headlines).  I just haven't
figured
>out how to make this not so greedy ... get just the subheads off the page
>and leave all of the headlines.
>
>Suggestions?
>
>H.
>
>
>=========================
>Howard Owens
>Web Producer
>InsideVC.com
>mailto:[EMAIL PROTECTED]
>=========================


------------------------------------------------------------------------------
Archives: http://www.eGroups.com/list/cf-talk
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to