Shea Martin
1/15/2007 7:55:00 PM
I often use \< and \> to denote the start and end of word. But they
don't seem to work with gsub. Am I missing something?
I would expect the following:
"xword1 word2 tword3".gsub( /\<word, 'XXXX' )
to return "xword1 XXXX2 tword3", but instead it the string unchanged.
If the \< and \> are not supported, is there an alternative that ruby
provides? Thanks.
Thanks,
~S