dougcranston
Technical User
I have a need to be able to format long strings for inclusion in an email message. I have one that works but it is VBScript. What I want is a Javascript function.
I am looking for a function that can take an string of text and based on the line length, insert \n at the nearest "blank" space.
Searching the web, I have found a couple of Javascripts that will break up text, but it does so at the exact line length resulting in words being split. Looks ugly. Example of one is found at:
Anyone have any suggestions?
Thanks in advance.
DougC
I am looking for a function that can take an string of text and based on the line length, insert \n at the nearest "blank" space.
Searching the web, I have found a couple of Javascripts that will break up text, but it does so at the exact line length resulting in words being split. Looks ugly. Example of one is found at:
Anyone have any suggestions?
Thanks in advance.
DougC