Controlling Word-Wrapping on Piped Email [message #162831] |
Thu, 29 July 2010 20:57 |
wittrs
Messages: 134 Registered: August 2009
Karma: 0
|
Senior Member |
|
|
I have an email group that pipes emails to a message board. The word wrap of the emails varies. In yahoo, the messages tend to fill the entire container on the message board. But in all other mail clients, only part of the container width is filled, because the original mail was wrapped. I want all of the email messages to fill the entire width of the container. The word-wrap feature in Global Settings will not accomplish this. I've turned it up, down and off -- there is no change.
I've thought of two possible solutions: a CSS insert, or a Regex that eliminates line breaks. Because I am only a garage mechanic (at these sorts of things), I simply cannot get the job done. Could any of you give me any sorts of leads as to how I might accomplish this?
Here is a link that shows the issue: http://seanwilson.org/forum/index.php?t=msg&th=1729&start=0&S=1 71399e41f2c10c4357dd9b217caaa3f
(compare the message of "sean" with that of "rob." One fills the container, the other not).
Can any of you suggest how to get all the mail to fill the container?
Much thanks in advance(as always).
|
|
|
|
Re: Controlling Word-Wrapping on Piped Email [message #162833 is a reply to message #162831] |
Fri, 30 July 2010 00:55 |
wittrs
Messages: 134 Registered: August 2009
Karma: 0
|
Senior Member |
|
|
Here is a regex string that works better. Just stick this in the administrative control panel where you have the maillist rules.
replace mask: '/([^\r\n]{50,})\r?\n(?!\r|\n)/'
replace with: "$1 "
(include a space after the 1.)
This allows you to eliminate word wrapping from incoming emails for lines 50 characters or more, by killing off the line breaks. If under 50, the line breaks stay put. This allows signature lines to be preserved (in practice) while allowing message bodies to fill up the container. I obviously did not write this. A dude on another list did. Just passing it along. Preliminary tests show it is doing the trick. The 50-character benchmark is, of course, not perfect. An intentional single-line break of a short sentence will defeat it, as will an extremely long signature line. But in practice it seems to do the job just fine.
|
|
|