JavaScript Newline Character -
from this question, ...
lines = foo.value.split(/\r\n|\r|\n/);
is 1 way split string, how join newlines?
also, wonder if linux uses whichever newline character, switch windows, won't web app break? newlines become not recognized? or maybe browser conversion?
split on /\r?\n/, in case string includes carriage returns newlines.
join '\n', in browser , os.
Comments
Post a Comment