textareas understanding linebreaks

Hello,
I'm working on a messaging system and I have a textarea that has some text where I do:
var text = window.document.message.reply.value;
to get the text,

but when the other person receives the message it is all on ONE line - it doesn't recognize line-breaks at all.

A second problem arises when I manually enter in line breaks "\n" and whatever else, and the message shows up fine, except the reply button will not work - there seems to be an error in the javascript because of the linebreaks - i imagine it happens because each line of the javascript is ended with text, instead of double quotes and a semicolon.

Any help would be appreciated,
Thanks!

David
[726 byte] By [Aikon3390] at [2007-11-19 11:27:24]