title: count new lines in textarea to resize container in PHP?
body: <p>I have a textarea submitted to a php file.</p>
  
  <p>Im using this to make it look exactly as the user entered the text:</p>
  
  <pre><code> $ad_text=nl2br(wordwrap($_POST['annonsera_text'], 47, "\n", true));
  </code></pre>
  
  <p>If I want to resize a container I must be able to read how many lines are in the variable '$ad_text'.</p>
  
  <p>Is there a way to do this...</p>
  
  <p>I am still learning so thanks for your help...</p>