Shouldn't the Text Helper use multibyte strings instead?

2007-12-15 Thread mclee
Hi, I'm using CakePHP 1.2.0.5875. When I dig into the code of Text Helper, I found out that in functions like truncate() or excerpt(), it calls substr() instead of multibyte friendly functions like mb_substr(). Will this be fixed? Or will there be another Text Helper for multibytes?

Re: Shouldn't the Text Helper use multibyte strings instead?

2007-12-15 Thread Gwoo
Does every php install have mb_substr() ? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Cake PHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to

Re: Shouldn't the Text Helper use multibyte strings instead?

2007-12-15 Thread mclee
Well, we have 'function_exists', don't we? Surely we can do a degrade if mb_substr is not installed. On Dec 16, 12:51 am, Gwoo [EMAIL PROTECTED] wrote: Does every php install have mb_substr() ? --~--~-~--~~~---~--~~ You received this message because you are

Re: Shouldn't the Text Helper use multibyte strings instead?

2007-12-15 Thread Chris Hartjes
On Dec 15, 2007 12:05 PM, mclee [EMAIL PROTECTED] wrote: Well, we have 'function_exists', don't we? Surely we can do a degrade if mb_substr is not installed. Are you volunteering to do it? -- Chris Hartjes My motto for 2007: Just build it, damnit! @TheKeyboard -

Re: Shouldn't the Text Helper use multibyte strings instead?

2007-12-15 Thread mclee
This is wierd, why so harsh? Is everybody allowed to commit back to the repository? I can send in my code on the Text Helper. On Dec 16, 3:24 am, Chris Hartjes [EMAIL PROTECTED] wrote: On Dec 15, 2007 12:05 PM, mclee [EMAIL PROTECTED] wrote: Well, we have 'function_exists', don't we?

Re: Shouldn't the Text Helper use multibyte strings instead?

2007-12-15 Thread Chris Hartjes
On Dec 15, 2007 3:26 PM, mclee [EMAIL PROTECTED] wrote: This is wierd, why so harsh? Is everybody allowed to commit back to the repository? I can send in my code on the Text Helper. Not harsh, just asking. I mean, if it's so simple then by all means submit a patch. Best way to do it is by

Re: Shouldn't the Text Helper use multibyte strings instead?

2007-12-15 Thread Gwoo
The plan with mb is to add support for it through the String class. If mb is not available the String class will handle it on its own. Several of the needed string functions exist and tests cover the current functionality. Then, the String class can be implemented in the TextHelper, among other