How to split all the lines ending with % in textarea to display to new line in div
<textarea id='all' rows="10" cols="100">
this is line one% this is line two% this is line three % this is line four %
</textarea>
<div id="split">
this is line one
this is line two
this is line three
this is line four
</div>