For example, if the following string is set to break at 25 characters, it would break the 'a' tag.
Code: Select all
This is example text, <a href='#'>link</a> more random text.Moderator: General Moderators
Code: Select all
This is example text, <a href='#'>link</a> more random text.Or do what keiran suggested..anjanesh wrote:Roaches - you got to write your own html parser to handle this.
markusn00b - what the OP is asking for is something like thismarkusn00b wrote:Or do what keiran suggested..anjanesh wrote:Roaches - you got to write your own html parser to handle this.
Code: Select all
$s = <<< endl
This is <b style="bad > style">example</b> text, <a href='#'>link</a> more random text
endl;
echo html_left($s, 20);
echo html_left($s, 24);