You left out one rather crucial bit of information: a variable
in what? Obviously not in HTML itself; it doesn't speak RegEx and isn't technically a language at all. No two languages speak exactly the same RegEx dialect.
Many programs distinguish between single-line and multi-line mode: the ^ and $ anchors can refer either to the very beginning and end of the whole document,
or to every single line break.
The string im trying to pick out is between a div and its closing tag.
Er, you mean the string is
within the div? i.e. between its opening and closing tags?
Do you know anything about what's inside the div, like what other tags might occur? I'm thinking something like
<div class = "blahblah">(([^<]*</?(?:p|i|span)(?: class = "\w+(?: \w+)*")?>)*[^<]*)</div>
but don't take my word for it without counting parentheses on your own fingers. If there are subsidiary divs, nest deeper. It can still be done.
Tip: "Disable graphic smile faces for this post" will look as if it isn't working in Preview, but in the real post it's just what you need. "Code" tags achieve the same purpose.