Thread
:
restricting regex to single lines of code?
View Single Post
01-26-2012, 11:23 PM
#
7
Serpentine
Evangelist
Posts: 416
Karma: 1045911
Join Date: Sep 2011
Location: Cape Town, South Africa
Device: Kindle 3
My guess would be something like this, tho I'm 90% asleep and off to bed... haven't tested it, but should work in most cases.
Code:
\?(\w[^?]+[[:punct:]])\? replace : “\1”
One of those times you really need to grep/list all the results to make sure.
Serpentine
View Public Profile
Find More Posts by Serpentine
Track Posts by Serpentine via RSS