Need to make a modification to the WikiName regex.
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
Thanks for any insight the gurus on this list can offer.
From: John Kershaw <lists@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:
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 ->
$RE = '/([[:upper:]]+)([[:upper:]][[:lower:]])/';
ie I commented out the first one and added in the second one.
Get latest updates about Open Source Projects, Conferences and News.