title: jQuery: keyup(): Update div with content from text area... line breaks?
body: <p>I have posted a working version here: <a href="http://jsfiddle.net/JV2qW/2/" rel="noreferrer">http://jsfiddle.net/JV2qW/2/</a></p>
  
  <p>I have a textarea that updates (on <code>keyup()</code>) a div with the text that is being entered. Everything is working as it should, except the line breaks are not being recognized. </p>
  
  <p>the html:</p>
  
  <pre><code>&lt;p&gt;enter text&lt;/p&gt;
  &lt;textarea id='text'&gt;&lt;/textarea&gt;
  &lt;div id='target'&gt;&lt;/div&gt;
  </code></pre>
  
  <p>and the jquery:</p>
  
  <pre><code>$('#text').keyup(function(){
        var keyed = $(this).val();
        $("#target").html(keyed);
   });
  </code></pre>
  
  <p>Any thoughts on how to get the <code>\n</code> translated to <code>&lt;br/&gt;</code> or <code>&lt;p&gt;</code> tags?</p>
  
  <p>many thanks.</p>