From: John K. <li...@ke...> - 2004-03-03 22:50:18
|
At 3:17 pm -0500 3/3/04, Micki Kaufman wrote: >We need a run of capital letters to be treated as a word, EXCEPT the >last of the capital letters... like this: > >ABCProductInfo should become ABC Product Info > >right now, it becomes ABCProduct Info Caveat: I'm still using 1.3.2. Your mileage may vary. I wanted the same thing for pages like this: http://www.through-the-maze.org.uk/pages/BTCVConservationVolunteers and made the following changes to my lib/stdlib.php file: /* // This splits the single-letter words 'I' and 'A' from any following capitalized words. $RE[] = '/(?: |^)([AI])([[:upper:]])/'; */ // Space before last capital in a run of caps: PCCMeeting -> PCC Meeting $RE[] = '/([[:upper:]]+)([[:upper:]][[:lower:]])/'; ie I commented out the first one and added in the second one. John. |