View Single Post
Old 05-19-2009, 09:57 AM   #48
Sweetpea
Grand Sorcerer
Sweetpea ought to be getting tired of karma fortunes by now.Sweetpea ought to be getting tired of karma fortunes by now.Sweetpea ought to be getting tired of karma fortunes by now.Sweetpea ought to be getting tired of karma fortunes by now.Sweetpea ought to be getting tired of karma fortunes by now.Sweetpea ought to be getting tired of karma fortunes by now.Sweetpea ought to be getting tired of karma fortunes by now.Sweetpea ought to be getting tired of karma fortunes by now.Sweetpea ought to be getting tired of karma fortunes by now.Sweetpea ought to be getting tired of karma fortunes by now.Sweetpea ought to be getting tired of karma fortunes by now.
 
Sweetpea's Avatar
 
Posts: 9,707
Karma: 32763414
Join Date: Dec 2008
Location: Krewerd
Device: Pocketbook Inkpad 4 Color; Samsung Galaxy Tab S6
Quote:
Originally Posted by pepak View Post
Actually, quotes, are quite doable using regular expressions. This regexp won't work 100%, but it will work most of the time:

Search = ([>_])’(.*?[^a-z_])’([<_])
Replace = $1opening_quote$2closing_quote$3

(note: underscore in the search string represents a space)
Could you explain that regex? My tool apparently uses a completely different form of regex....

Edit:
(never mind that, I have to escape the ( and ) ...)

But, once I got it working I noticed something else:

Quote:
<p>'What if,' she said, 'there's something like this?'</p>

Last edited by Sweetpea; 05-19-2009 at 10:05 AM.
Sweetpea is offline   Reply With Quote