title: Trim leading/trailing whitespace from textarea using jQuery?
body: <p>Following code is an example of text placed into a textarea from a database.</p>
  
  <pre><code>&lt;textarea id="inputPane" cols="80" rows="40" class="pane"&gt;
  &lt;p&gt;
      some text here...
  &lt;/p&gt;
    &lt;p&gt;
      more text here...
  &lt;/p&gt;
  &lt;/textarea&gt;
  </code></pre>
  
  <p>using jQuery's .trim what is the actual jquery code to remove all leading and trailing whitespace and have the textarea display very similar to below?</p>
  
  <pre><code>&lt;textarea id="inputPane" cols="80" rows="40" class="pane"&gt;
      &lt;p&gt;some text here...&lt;/p&gt;
      &lt;p&gt;more text here...&lt;/p&gt;
  &lt;/textarea&gt;
  </code></pre>
  
  <p>I've worked on this for hours with no success trying varying combinations with .trim</p>
  
  <pre><code>$('#inputPane')jQuery.trim(string);
  </code></pre>