Carriage returns causing problems in REST request?

following seems to do the trick:

var wn_formatted =  work_notes.replace(/\r?\n|\r/g, ';'); //replaces carriage return with ;

since discovered that using JSON.stringify() on the string, and setStringParameter
in lieu of setStringParameterNoEscape in the REST message
is safer belt and braces!


Popular posts from this blog

GlideRecord setValue

URL link in addInfoMessage

variable advanced reference qualifier example