"함수 utf8 strlen()"의 두 판 사이의 차이

6번째 줄: 6번째 줄:
<source lang='PHP'>
<source lang='PHP'>
function utf8_strlen($str) { return mb_strlen($str, 'UTF-8'); }
function utf8_strlen($str) { return mb_strlen($str, 'UTF-8'); }
echo utf8_strlen('12345');
# 5
echo utf8_strlen('안녕하세요');
# 5
</source>
</source>



2016년 11월 7일 (월) 09:44 판

utf8_strlen

1 PHP

function utf8_strlen($str) { return mb_strlen($str, 'UTF-8'); }

echo utf8_strlen('12345');
# 5
echo utf8_strlen('안녕하세요');
# 5

2 같이 보기

3 참고 자료

문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}