| Newsgroups |
php.notes |
| Message-ID |
<[email protected]> |
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
----
Server IP: 45.112.84.4
Probable Submitter: 80.90.5.137 (proxied: 2a02:2a40:17fb:1000:5d37:65fc:d5df:54be)
----
Manual Page -- https://php.net/manual/en/function.mb-ucfirst.php
Edit -- https://main.php.net/note/edit/130554
Del: integrated -- https://main.php.net/note/delete/130554/integrated
Del: useless -- https://main.php.net/note/delete/130554/useless
Del: bad code -- https://main.php.net/note/delete/130554/bad+code
Del: spam -- https://main.php.net/note/delete/130554/spam
Del: non-english -- https://main.php.net/note/delete/130554/non-english
Del: in docs -- https://main.php.net/note/delete/130554/in+docs
Del: other reasons-- https://main.php.net/note/delete/130554
Reject -- https://main.php.net/note/reject/130554
Search -- https://main.php.net/manage/user-notes.php