THE WORLD'S LARGEST WEB DEVELOPER SITE

PHP lcfirst() Function

PHP String Reference PHP String Reference

Example

Convert the first character of "Hello" to lowercase:

<?php
echo lcfirst("Hello world!");
?>

Run example »

Definition and Usage

The lcfirst() function converts the first character of a string to lowercase.

Related functions:

  • ucfirst() - converts the first character of a string to uppercase
  • ucwords() - converts the first character of each word in a string to uppercase
  • strtoupper() - converts a string to uppercase
  • strtolower() - converts a string to lowercase

Syntax

lcfirst(string)

Parameter Description
string Required. Specifies the string to convert

Technical Details

Return Value: Returns the converted string
PHP Version: 5.3.0+

PHP String Reference PHP String Reference

COLOR PICKER

colorpicker

SHARE THIS PAGE






Search w3schools.com:

Translate w3schools.com: