On May 13, 2014, at 4:51 AM, jgill <[email protected]> wrote:
> 
> I want to search for all the text within a <div id="mydiv">.......</div> 
> which is across multiple lines.
> 
> <div id="mydiv">.*?</div> doesn't work because . does not include line returns
> 
> Is there a way in BBEdit to force . to include returns or is there some other 
> way of doing this?

Put (?s) at the beginning of the search expression, thus:

        (?s)<div id="mydiv">.*?</div>

"s" is the pattern modifier, meaning "dot will match any character (including 
newline)".

See the BBEdit help, Searching with Grep, Advanced Grep Topics.

- Neil Faiman

-- 
This is the BBEdit Talk public discussion group. If you have a 
feature request or would like to report a problem, please email
"[email protected]" rather than posting to the group.
Follow @bbedit on Twitter: <http://www.twitter.com/bbedit>

--- 
You received this message because you are subscribed to the Google Groups 
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].

Reply via email to