PHP strtolower() function with example

By IncludeHelp Last updated : December 27, 2023

PHP strtolower() function

The strtolower() function is a string function, it accepts the string and returns an lowercase string.


The syntax of the strtolower() function:



The parameters of the strtolower() function:

  • string: An input parameter.

Sample Input/Output

Input: "This is my COMPUter!"
Output: "this is my computer!"

Example of PHP strtolower() Function

$str = "This is my COMPUter!";

echo (strtolower($str));


The output of the above example is:

this is my computer!

To understand the above example, you should have the basic knowledge of the following PHP topics:

All PHP Programs

Comments and Discussions!

Load comments ↻

Copyright © 2024 All rights reserved.