We have a real bizarre problem when we make a message, line ending \r\n , but when we pull the value using javascript, it just gets \n . This causes problems because for our system, the creation will do the message of the usual form, and the update will pull the values ββfrom the form to create the ajax request. Later we do a string comparison over a given field and see that this weird mix between \r exists or does not exist.
IE handles this tone (ALWAYS \r\n ), FF on windows will send using \r\n , and only \n will be reported in javascript. What is REALLY FREAKIN STRANGE, although this is on Linux, firefox, and chrome will be placed with \r\n , and when you execute document.getElementById('text-area-id').value will always be displayed only \n .
Is this some kind of dusty corner of the HTTP spec or something like that? Do browsers implement this so that Windows servers do not die? Is there a way around this and then sanitize each area? What I expect is both JS and HTTP POST to behave the same and use the default system on any system they are on.
source share