Thread: Regex examples
View Single Post
Old 04-16-2014, 12:08 PM   #327
Doitsu
Grand Sorcerer
Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.
 
Doitsu's Avatar
 
Posts: 5,582
Karma: 22735033
Join Date: Dec 2010
Device: Kindle PW2
Quote:
Originally Posted by Jellby View Post
But it would also find it between two <i></i> blocks, wouldn't it?
You're are of course right, but as DiapDealer has already pointed out, it's pretty much impossible to come up with a regex that covers all possible permutations. However, my simple regex covers at least the three most likely scenarios. I.e., an initial, medial or final occurrence of the search string.
Doitsu is offline   Reply With Quote