How to use ctype_alpha with UTF-8
I have this code:
if(empty($_POST) === false) {
if (isset($_POST['first_name']) && !empty ($_POST['first_name'])){
if (ctype_alpha($_POST['first_name']) === false) {
$errors[] = 'Please enter your First Name with only letters!';
}
}
so here I chech is everzthing fine if not I got error...
But If I use letters like ščćž - UTF-8 then I also get errors, so how I can sovle this problem becouse I need for first name to have onlz letters but I need to allow UTF-8 characters like ščćž
Please help!