title: PHP textarea security
body: <p>When user chooses his <code>username</code> I do the following:</p>
  
  <pre><code>if($_POST['username'] != "") {
      $username = trim($_POST['username']);
      $username = filter_var($username, FILTER_SANITIZE_STRING, FILTER_FLAG_STRIP_LOW);
  }
  </code></pre>
  
  <p>But how to work with textarea´s, there is no option working with <code>filter_var</code>/<code>filter_input</code>, so what security do I need to include?</p>
  
  <blockquote>
    <p>strip_tags</p>
    
    <p>htmlspecialchars</p>
    
    <p>htmlentities</p>
  </blockquote>
  
  <p>You have any advices?</p>
  
  <p>Greetings!</p>