title: How to replace '\n' in string with '<br>' in Flask app?
body: <p>I've been trying to modify a string before passing it to my HTML page in Flask (replacing occurrences of '\n' with '&lt;br&gt;'), but the typical methods I use aren't working for some reason.</p>
  <pre class="lang-py prettyprint-override"><code>finalstring = textstring.replace('\n', '&lt;br&gt;')
  return render_template('my-form-result.html', emailresponse = finalstring)
  </code></pre>
  <p>This should work, but for some reason, nothing is replaced. How can I get this to work? Thanks!</p>