Search results
ucfirst — Make a string's first character uppercase. Description. ucfirst (string $string): string. Returns a string with the first character of string capitalized, if that character is an ASCII character in the range from "a" (0x61) to "z" (0x7a). Parameters. string. The input string. Return Values. Returns the resulting string. Changelog.
- Substr
Parameters. string. The input string. offset. If offset is...
- Str replace
Parameters. If search and replace are arrays, then...
- Strpos
Strpos - PHP: ucfirst - Manual
- Number format
Version Description; 8.0.0: Prior to this version,...
- Implode
Implode - PHP: ucfirst - Manual
- Strlen
PHP's strlen function behaves differently than the C strlen...
- Substr
Learn how to use the ucfirst () function to convert the first character of a string to uppercase in PHP. See the syntax, parameter values, return value, and examples of this function.
9 kwi 2010 · You need the ucfirst function. Returns a string with the first character of str capitalized, if that character is alphabetic. It will not make the other characters lowercase. To make sure only the first letter is upper case and rest all are lowercase you can do: ucfirst(strtolower($str)) edited Apr 9, 2010 at 9:56.
ucwords — Uppercase the first character of each word in a string. Description. ucwords (string $string, string $separators = " \t\r\n\f\v"): string. Returns a string with the first character of each word in string capitalized, if that character is an ASCII character between "a" (0x61) and "z" (0x7a).
5 lip 2021 · You can use PHP’s ucfirst () function to change the first character of a string to upper case. You can also use the strtolower () function in combination with the ucfirst () function if you want only the first letter of the string to be capitalized and the rest of the string to be lowercase.
Learn how to use the PHP ucfirst() function to convert the first alphabetic character of a string to uppercase. See examples, syntax, and how to deal with multibyte characters.
You can use the PHP ucfirst() function to change the first character of a string to uppercase (i.e. capital). Alternatively, you can use the strtolower() function in combination with the ucfirst() function, if you want to make only first letter of the string to uppercase and rest of the string to lowercase.