Wow, it even uses '...' by default.  I am not a huge fan of filters though,
just cause of the need of an [% END %].

Thanks,
Earl

> -----Original Message-----
> From: Larry Leszczynski [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, March 15, 2005 2:18 PM
> To: Cahill, Earl
> Cc: [email protected]
> Subject: Re: [Templates] a little text formatting
> 
> 
> On Tue, 15 Mar 2005, Cahill, Earl wrote:
> 
> > A start with a line, say
> >
> > This line is really too long.
> >
> > A length, say 25, and suffix, say '...'.  I would like to be able to do
> > something like this
> >
> > [% my_truncate(line, 25, '...') %]
> >
> > And end up with
> >
> > This line is really t...
> 
> 
> Um, maybe you could use "truncate()"?
> 
> http://template-
> toolkit.org/docs/default/Manual/Filters.html#truncate_length_
> 
> :-)
> 


_______________________________________________
templates mailing list
[email protected]
http://lists.template-toolkit.org/mailman/listinfo/templates

Reply via email to