[TYPO3-project-formidable] How to use data.fixed_lgd(nbchars, "...") ?

Luc Muller l.mul-nospam-ler at ameos.com
Wed May 21 10:08:47 CEST 2008


Hello Ian

You better should call the function this way : {title.fixed_lgd("10", 
"...")}

It should work. by the way, it works on our server.

Be sure, the data you're cropping is not plain html. as tags can be cutted.

If you want to crop HTML data just add a striptags before

{title.striptags().fixed_lgd("10", "...")}

Another method for this exists thus is easier to remember : 
{title.substr("10", "...")}

Luc Muller


Ian Solo a écrit :
> Hello,
> I'm trying to crop a title in my template using the string method:
> data.fixed_lgd(nbchars, "...")
>
> I use:
> {title.fixed_lgd(10, "...")}
> in my template, but it doesn't crop the title.
>
> What am I doing wrong?
>
> Tnx!ian


-- 

*Luc Muller*
/Web Developper/
/Formidable - Rapid Application Developpement Framework for Typo3 
<http://formidable.typo3.ug>/
/Typo3 Ameos <http://www.ameos.com>/



More information about the TYPO3-project-formidable mailing list