Home > Backend Development > PHP Tutorial > How to use php strtolower function

How to use php strtolower function

藏色散人
Release: 2023-04-04 22:18:01
Original
4104 people have browsed it

php The strtolower function is used to convert strings to lowercase. The syntax of strtolower is strtolower(string). The parameter string is required and specifies the string to be converted.

How to use php strtolower function

php How to use strtolower function?

Function: Convert all characters to lowercase

Syntax:

strtolower(string)
Copy after login

Parameters:

string Required, specifies the string to be converted

Description: The strtolower() function converts a string to lowercase. This function is binary safe.

php strtolower() function usage example 1:

<?php
$i = "HELLO WORLD";
$j = strtolower($i);
echo $j;
?>
Copy after login

Output:

hello world
Copy after login

php strtolower() function usage example 2:

<?php
$i = "I&#39;M STUDY IN PHP.CN";
$j = strtolower($i);
echo $j;
?>
Copy after login

Output:

i&#39;m study in php.cn
Copy after login

This article is an introduction to the PHP strtolower function. I hope it will be helpful to friends in need!

The above is the detailed content of How to use php strtolower function. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template