Fix for strings with extra newlines/carriage returns

The \n escaping is working fine, but for HTML output that still has weird returns, Javascript will take that as a newline and throw an "Unterminated string literal" error in the browser-side. Removing \R after the \n have been escaped solves the issue.