title: PHP Regex validate letters and Spanish accent
body: <p>How can I add/improvised my code so Spanish accent will be considered as valid in addition to normal alphabet (a-z)</p>
  
  <p>I have the following in my code</p>
  
  <pre><code>public static function IsAlpha($s){
    $reg = "#[^a-z\s-]#i";
    $count = preg_match($reg, $s, $matches);
    return $count == 0;
  }
  </code></pre>