[Typo3-dev] crop whole words and utf-8 SOLVED
Martin Kutschker
martin.kutschker-n0spam at no5pam-blackbox.net
Fri Nov 11 21:48:56 CET 2005
Toni Milovan schrieb:
> Hi to all that helped.
>
> I have finally managed to solve this problem:
>
> The problem generally is that tt_news does not use standard crop
> function from class.tslib_content.php, but crop function from
> class.t3lib_cs.php instead.
>
> And while this function has utf-8 handling built in, it does not have a
> possibility to accept third parameter for croping of whole words.
No it hasn't. It was just meant as a replacemnt for straightforward
cropping.
But of course, as you have shown it's possible to do enhance the
function. But is lookign for a space enough? What about non breakings
spaces and other white spaces found in Unicode?
> Even more, it seems that tt_news does not forwards charset parameter to
> this function.
All string handling functions in t3lib_cs expect a charset (only some
internal functions work on specific charsets).
Masi
More information about the TYPO3-dev
mailing list