title: How to check if a string is in an array?
body: <p>I basically need a function to check whether a string's characters (each character) is in an array.</p>
  
  <p>My code isn't working so far, but here it is anyway,</p>
  
  <pre><code>$allowedChars = array("a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"," ","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"," ","0","1","2","3","4","5","6","7","8","9"," ","@",".","-","_","+"," ");
  
  $input = "Test";
  $input = str_split($input);
  
  if (in_array($input,$allowedChars)) {echo "Yep, found.";}else {echo "Sigh, not found...";}
  </code></pre>
  
  <p>I want it to say 'Yep, found.' if one of the letters in $input is found in <code>$allowedChars</code>.  Simple enough, right?  Well, that doesn't work, and I haven't found a function that will search a string's individual characters for a value in an array.</p>
  
  <p>By the way, I want it to be just those array's values, I'm not looking for fancy html_strip_entities or whatever it is, I want to use that exact array for the allowed characters.</p>