title: Get each line from textarea
body: <pre><code>&lt;textarea&gt; put returns between paragraphs
  for linebreak add 2 spaces at end
  indent code by 4 spaces
  quote by placing &gt; at start of line
  &lt;/textarea&gt;
  
  $text = value from this textarea;
  </code></pre>
  
  <p><strong>How to:</strong></p>
  
  <p><strong>1) Get each line from this textarea (<code>$text</code>) and work with them using <code>foreach()</code>?</strong></p>
  
  <p><strong>2) Add <code>&lt;br /&gt;</code> to the end of each line, except the last one?</strong></p>
  
  <p><strong>3) Throw each line to an array.</strong></p>
  
  <p><strong>Important</strong> - text inside textarea can be multilanguage.</p>
  
  <hr>
  
  <p>Have tried to use:</p>
  
  <pre><code>$text = str_replace('\n', '&lt;br /&gt;', $text);
  </code></pre>
  
  <p>But it doesn't work.</p>
  
  <hr>
  
  <p>Thanks.</p>