I have a regular expression that works fine for anything us-EN and as far as I know it used to work with alternate charsets before something changed, what that was I cannot tell you but it is not working as expected
βαρίδι -> bob
function validateNames($name)
{
if (preg_match('!^([a-zA-Z]{3,25})$!', $name))
return true;
return false;
}
//returns false
print validateNames(βαρίδι😉;
//returns true
print validateNames(bob);
Everything else works as expected if I don't do the check it will insert into the db and pull as correct encoding without issue.
I also tried setting ctype_alpa and setting a locale but that didn't work either.
utf8 is set as the charset
Can someone help point me in the right direction to resolve this
Best Regards,
Brandon