function Unicode::strtolower

Converts a UTF-8 string to lowercase.

Parameters

string $text: The string to run the operation on.

Return value

string The string in lowercase.

Deprecated

in drupal:8.6.0 and is removed from drupal:9.0.0. Use mb_strtolower() instead.

See also

https://www.drupal.org/node/2850048

1 call to Unicode::strtolower()
UnicodeTest::testStrtolower in core/tests/Drupal/Tests/Component/Utility/UnicodeTest.php
Tests multibyte strtolower.

File

core/lib/Drupal/Component/Utility/Unicode.php, line 307

Class

Unicode
Provides Unicode-related conversions and operations.

Namespace

Drupal\Component\Utility

Code

public static function strtolower($text) {
    @trigger_error('\\Drupal\\Component\\Utility\\Unicode::strtolower() is deprecated in Drupal 8.6.0 and will be removed before Drupal 9.0.0. Use mb_strtolower() instead. See https://www.drupal.org/node/2850048.', E_USER_DEPRECATED);
    return mb_strtolower($text);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.