Timothy Johnson wrote:
Will the string always have the two quotes in the same place and only


Well, it could have multiple {} inside or outside of multiple "" AFAIK.

one per string?  What about something like this?

/.*?\{([^\}]*)\}(?=.*")/gi

That does work on that exact string, I'll have to study it a bit, thanks!

-----Original Message-----
From: JupiterHost.Net [mailto:[EMAIL PROTECTED] Sent: Thursday, April 13, 2006 5:16 PM
To: beginners@perl.org
Subject: regex matching conditionally

Howdy list,


I'm trying to see if I can do this in one regex instead of multiple stage, mainly for educational purposes since I already have it in multipel steps.

I am trygin to get each string between { and } where the {} occurs between double quotes. So with "file.optcondition={/Root/Get/Peter}&ampc={/Root/Get/do}&bleah"={/Root/B
lah}

I want /Root/Get/Peter and /Root/Get/do

<snip>





--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to