Am 22.03.2010 um 15:00 schrieb RobS:
> Can someone suggest a grep that will select all text on one line which
> follows an opening span tag (see example below) and which precedes a
> closing tag which is not a span?
> 
> <p>First line<br />
> another line<br />
> <span class="ind2">another line<br />
> another line<br />
> <span class="ind2">last line.</p>
> 
> ...and I need to close the spans.

To come up with a quick and dirty grep solution:

Search:
(<span.+?>.+?)(<.+>)
Replace:
\1</span>\2

this pattern might misbehave on certain circumstances:
- it assumes that the opening span tags contain arguments
- it assumes that each line has a tag at it's end

But maybe it does work for you.

Regards
Roland Küffner



> 
> -- 
> You received this message because you are subscribed to the 
> "BBEdit Talk" discussion group on Google Groups.
> To post to this group, send email to bbedit@googlegroups.com
> To unsubscribe from this group, send email to
> bbedit+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/bbedit?hl=en
> If you have a feature request or would like to report a problem, 
> please email "supp...@barebones.com" rather than posting to the group.
> 
> To unsubscribe from this group, send email to 
> bbedit+unsubscribegooglegroups.com or reply to this email with the words 
> "REMOVE ME" as the subject.

-- 
You received this message because you are subscribed to the 
"BBEdit Talk" discussion group on Google Groups.
To post to this group, send email to bbedit@googlegroups.com
To unsubscribe from this group, send email to
bbedit+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/bbedit?hl=en
If you have a feature request or would like to report a problem, 
please email "supp...@barebones.com" rather than posting to the group.

To unsubscribe from this group, send email to 
bbedit+unsubscribegooglegroups.com or reply to this email with the words 
"REMOVE ME" as the subject.

Reply via email to