
That works. But here’s another question: why is the outer group with the ? operator required? I tried just (.|\n)*, which should match anything between my start and end strings, but it does not, where ((.|\n)*?) does. Thanks, E. -- Eliot Kimber Senior Solutions Architect "Bringing Strategy, Content, and Technology Together" Main: 512.554.9368 www.reallysi.com www.rsuitecms.com On 1/11/14, 3:08 PM, "G. Ken Holman" <gkholman@CraneSoftwrights.com> wrote:
At 2014-01-11 13:17 -0600, Eliot Kimber wrote:
Content-Language: en-US Content-Type: text/plain; charset="utf-7"
Im trying to a regular expression search and replace for things like this:
doc: text text next line next line/a:documentation
What I cant figure out is how to do this multi-line regular expression match. If use dot matches all then my match is not limited to just whats shown but everything between the first doc: and the last /a:documentation.
If do e.g. doc:(.)/a:documentation then it matches cases where it all happens to be on one line.
Is this possible? What bit of regex fu am I missing?
I think it is the use of "\n".
Try this to include all of the lines: doc:((.|\n)*?):documentation
(note that I'm guessing what your boundaries are because of a mailer problem)
I hope this helps.
. . . . . . . . Ken
-- Public XSLT, XSL-FO, UBL & code list classes: Melbourne, AU May 2014 | Contact us for world-wide XML consulting and instructor-led training | Free 5-hour lecture: http://www.CraneSoftwrights.com/links/udemy.htm | Crane Softwrights Ltd. http://www.CraneSoftwrights.com/x/ | G. Ken Holman mailto:gkholman@CraneSoftwrights.com | Google profile: http://plus.google.com/麜稥馩Crane/about | Legal business disclaimers: http://www.CraneSoftwrights.com/legal |
_______________________________________________ oXygen-user mailing list oXygen-user@oxygenxml.com http://www.oxygenxml.com/mailman/listinfo/oxygen-user