in reply to Breaking "long" lines of non-space-seperated characters
$line =~ s/(\S{80})/$1 /g;
Of course, that won't work if $line contains HTML, because it might insert the space inside of a tag, and it wouldn't count tags as a space when it should (e.g. <p>).
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Breaking "long" lines of non-space-seperated characters
by xdg (Monsignor) on Aug 16, 2005 at 16:25 UTC | |
|
Re^2: Breaking "long" lines of non-space-seperated characters
by skx (Parson) on Aug 16, 2005 at 15:57 UTC |