invvsz invvsz - 1 month ago 12
PHP Question

Preg match in expression with array

I'm getting

syntax error, unexpected '{'
in the following line:

} elseif (!preg_match('/^[a-zA-Z ]*$/',$msz['letters']) {


What am I missing here?

Answer

You're missing a closing ) after $msz['letters'].