[thelist] Regex apostrophe problem

VOLKAN ÖZÇELİK volkan.ozcelik at gmail.com
Thu Aug 18 15:39:03 CDT 2005


Replaced + with *

([\w]{1})([\w]*)

Tested with

VOLKAN OZCELIK
VOLKAN O ' ZCELIK (added space just to make apos stand out)
VOLKAN OZ ' CELIK

It matches as expected.

HTH,
Volkan.


On 8/17/05, fstorr <fffrancis at fstorr.demon.co.uk> wrote:
> Hi all
> 
> I'm trying to write a regex that will change the case of text from
> all upper to title case so, from BOB O'NEIL to Bob O'Neil.  I'm
> getting stuck where apostrophes come into play as the N after the
> apostrophe needs to be capitalised along with the preceding O.  I've
> got this so far:
> 
> Find: ([\w]{1})([\w]+)
> Replace: $1\L\$
> 
> But don't know how to deal with the apostrophes.  Is it possible to
> do this, and if so, how?
> 
> regards
> 
> Francis
> 
> --
> 
> * * Please support the community that supports you.  * *
> http://evolt.org/help_support_evolt/
> 
> For unsubscribe and other options, including the Tip Harvester
> and archives of thelist go to: http://lists.evolt.org
> Workers of the Web, evolt !
>


More information about the thelist mailing list