RE: Re: truncating html text


#1

Why don’t you truncate the text before you wrap it in the tags? This
would be the easiest way to avoid the problem.


#2

Tom F. wrote:

Why don’t you truncate the text before you wrap it in the tags? This
would be the easiest way to avoid the problem.

I’m starting with textile markup text, so there will be some decoration
in there even before I convert it to html. Doing the truncate on the
markup is better because you are less likely to cut a tag in half, and
because when you do the conversion to html, you don’t get malformed html
tags.

This is an intermediate solution for now.