Unicode::lcfirst

public static function Unicode::lcfirst

public static Unicode::lcfirst($text)

Converts the first character of a UTF-8 string to lowercase.

Parameters

string $text: The string that will be converted.

Return value

string The string with the first character as lowercase.

Related topics

PHP wrapper functions
Functions that are wrappers or custom implementations of PHP functions.

File

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

Class

Unicode
Provides Unicode-related conversions and operations.

Namespace

Drupal\Component\Utility

Code

public static function lcfirst($text) {
  // Note: no mbstring equivalent!
  return static::strtolower(static::substr($text, 0, 1)) . static::substr($text, 1);
}

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Component!Utility!Unicode.php/function/Unicode::lcfirst/8.1.x

在线笔记
App下载
App下载

扫描二维码

下载编程狮App

公众号
微信公众号

编程狮公众号

意见反馈
返回顶部