You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
usekdn\yii2\validators\DomainValidator;
$validator = newDomainValidator(['enableIDN' => true]);
// "ф" is cyrillic symbol, only 69 characters, but after conversion to ASCII will be 255$validator->validate(str_repeat('ф.', 31) . 's.s.s.s', $error);
echo$error;
What is the expected result?
the input value is too long.
What do you get instead?
Fatal error: idn_to_ascii(): ICU returned an unexpected length.
Additional info
Q
A
Extension version
All
Yii version
All
PHP version
All
HHVM version
-
Operating system
All
Solution
There was bug in PHP function idn_to_ascii, it was fixed in PHP 5.6 and PHP 7, please upgrade PHP or consider switching to HHVM.
The text was updated successfully, but these errors were encountered:
What steps will reproduce the problem?
Fatal error occurs if used PHP, IDN enabled and domain name length is exactly 255 characters in ASCII representation.
Other way
What is the expected result?
the input value is too long.
What do you get instead?
Fatal error: idn_to_ascii(): ICU returned an unexpected length.
Additional info
Solution
There was bug in PHP function
idn_to_ascii
, it was fixed in PHP 5.6 and PHP 7, please upgrade PHP or consider switching to HHVM.The text was updated successfully, but these errors were encountered: