This won't work if you have nested span tags > -----Original Message----- > From: Scott Stroz [mailto:[EMAIL PROTECTED] > Sent: 03 December 2004 18:12 > To: CF-Talk > Subject: Re: RegEx (again!) > > Actually, this is something you can easily do with RegEx. > > reReplaceNoCase(textString, "<span>(.*?)</span>", "\1","ALL") > > Should remove all <span> and </span> tags where no attributes are set, > but leave whatever is in between.. > > > On Fri, 3 Dec 2004 09:39:01 -0500, Duane Boudreau <[EMAIL PROTECTED]> > wrote: > > I start with > > <P><SPAN>Duane</SPAN></P><P><SPAN > style=text>[EMAIL PROTECTED]</SPAN></P> > > > > I want to end with > > <P>Duane</P><P><SPAN style=text>[EMAIL PROTECTED]</SPAN></P> > > > > I want to remove the span tag without attributes and its ending tag, > leaving > > behind what ever text was in between. > > > > Duane > > > > > > > > > > -----Original Message----- > > From: Dawson, Michael [mailto:[EMAIL PROTECTED] > > Sent: Thursday, December 02, 2004 8:42 PM > > To: CF-Talk > > Subject: RE: RegEx (again!) > > > > I'm a bit confused. Are you wanting to remove all SPAN tags and leave > > everything else? > > > > Can you give an example of what you want the text to look like AFTER the > > regex operation? > > > > Thanks > > > > -----Original Message----- > > From: Duane Boudreau [mailto:[EMAIL PROTECTED] > > Sent: Thursday, December 02, 2004 6:58 PM > > To: CF-Talk > > Subject: RegEx (again!) > > > > I thought I was finally catching on to this regex stuff but I guess not. > > > > I am using a tag from the developer exchange that strips a bunch of > > extra html that Word inserts into an HTML document. The text left over > > leaves a lot of extra <span>xyx</span> formatting. Since the opening > > <span> is empty I would like to remove them from the text. I tried this > > but no luck. > > > > textString = "<P><SPAN><b>Duane > > Boudreau</b></SPAN></P><P><SPAN>[EMAIL PROTECTED]</SPAN></P>"; > > > > textString = reReplaceNoCase(textString, "<span>([^</span>]*)</span>", > > "\1", "ALL"); > > > > I thought that the text between the () meant all text except </span> > > between the opening string "<span>" and the next "</span>" > > > > What am I doing wrong here? > > > > Thanks, > > Duane > > > > > >
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Special thanks to the CF Community Suite Silver Sponsor - CFDynamics http://www.cfdynamics.com Message: http://www.houseoffusion.com/lists.cfm/link=i:4:186122 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54