bp_core_ucfirst( string $str )
Multibyte-safe ucfirst() support.
Description Description
Uses multibyte functions when available on the PHP build.
Parameters Parameters
- $str
-
(Required) String to be upper-cased.
Return Return
(string)
Source Source
File: bp-members/bp-members-functions.php
function bp_core_ucfirst( $str ) { if ( function_exists( 'mb_strtoupper' ) && function_exists( 'mb_substr' ) ) { $fc = mb_strtoupper( mb_substr( $str, 0, 1 ) ); return $fc.mb_substr( $str, 1 ); } else { return ucfirst( $str ); } }
Changelog Changelog
Version | Description |
---|---|
1.0.0 | Introduced. |