title: inserting line breaks in text quoted in javascript
body: <p>Doing some text swapping (testimonials fade in/out) with JavaScript and want to insert the equivalent of a <code>&lt;br/&gt;</code> inside the quotes so the author of the quote is on the next line. In the below code, I tried following the instructions at <a href="https://stackoverflow.com/questions/863779/textarea-line-breaks-javascript">JavaScript: How to add line breaks to an HTML textarea?</a>, but am not sure how to insert <code>/\n\r?/g</code> to make it work.</p>
  
  <pre><code>&lt;script type="text/javascript"&gt;
      var text = document.forms[0].txt.value;
      text = text.replace(/\n\r?/g, '&lt;br /&gt;');
  &lt;/script&gt;
  
  &lt;script type="text/javascript"&gt;
  
      window.testimonials = [
          '"This was a great experience" /\n\r?/g - Max Cameron, ThinkTank',
          '"This was a great experience" /\n\r?/g - Max Cameron, ThinkTank',
          "source code"
      ];
  &lt;/script&gt;
  </code></pre>
  
  <p>Is there any way to force it onto the next line? Thanks!</p>