是的,strtolower() 函数在 PHP 中可以批量转换字符串。您可以使用循环遍历数组中的每个元素并将其转换为小写。以下是一个示例:
<?php
$strings = array("Hello", "WORLD!", "ExaMple", "WITH", "UPPER", "AND", "LOWERCASE");
foreach ($strings as $key => $value) {
    $strings[$key] = strtolower($value);
}
print_r($strings);
?>
输出结果:
Array
(
    [0] => hello
    [1] => world!
    [2] => example
    [3] => with
    [4] => upper
    [5] => and
    [6] => lowercase
)
在这个示例中,我们创建了一个包含大写和小写字符串的数组 $strings。然后,我们使用 foreach 循环遍历数组中的每个元素,并使用 strtolower() 函数将其转换为小写。最后,我们打印出修改后的数组。

 便宜VPS测评
便宜VPS测评










