Home » PHP

PHP lcfirst() function with example

PHP lcfirst() function: Here, we are going to learn about the lcfirst() function with example.
Submitted by IncludeHelp, on February 03, 2019

PHP lcfirst() function

lcfirst() function is a string function, it is used to convert first character to lowercase. It accepts string and returns string with first lowercase character.

Syntax:

    lcfirst(string);

Example:

    Input: "THIS is MY computer!"
    Output: "tHIS is MY computer!"

PHP code:

<?PHP
    $str = "THIS is MY computer!";
    
    echo (lcfirst($str));
?>

Output

tHIS is MY computer!





Comments and Discussions

Ad: Are you a blogger? Join our Blogging forum.
Learn PCB Designing: PCB DESIGNING TUTORIAL




Languages: » C » C++ » C++ STL » Java » Data Structure » C#.Net » Android » Kotlin » SQL
Web Technologies: » PHP » Python » JavaScript » CSS » Ajax » Node.js » Web programming/HTML
Solved programs: » C » C++ » DS » Java » C#
Aptitude que. & ans.: » C » C++ » Java » DBMS
Interview que. & ans.: » C » Embedded C » Java » SEO » HR
CS Subjects: » CS Basics » O.S. » Networks » DBMS » Embedded Systems » Cloud Computing » Machine learning » CS Organizations » Linux » DOS
More: » Articles » Puzzles » News/Updates

© https://www.includehelp.com some rights reserved.