Validation
Validation copied to clipboard
wrong length of unicode characters
strlen() is not handling multibyte characters correctly, as it assumes 1 char equals 1 byte, which is simply invalid for unicode. The solution is to use mb_strlen() function