For non-english words enconded in utf-8 works mb_convert_case with MB_CASE_TITLE option
mb_convert_case(mb_substr($str, 0, 1), MB_CASE_TITLE) . mb_substr($str, 1);
For a single word
echo mb_convert_case('çağla', MB_CASE_TITLE);
https://stackoverflow.com/questions/25729900/ucfirst-doesnt-work-on-non-english-characters