title: Jquery Replacing space in string with html <br /> tag
body: <p>I want to replace spaces in a string with a html <code>&lt;br /&gt;</code> tag, whats the best way of doing this?. Currently I have this code which replaces the spaces with a "-". </p>
  
  <pre><code>$(".msn").each(function() {
      $(this).text($(this).text().replace(/ /g, '-'));
  });
  </code></pre>