每个单词的首字母转换为大写:ucwords()
<?php
$foo = \'hello world!\';
$foo = ucwords($foo); // Hello World!
$bar = \'HELLO WORLD!\';
$bar = ucwords($bar); // HELLO WORLD!
$bar = ucwords(strtolower($bar)); // Hello World!
?>
本文地址:https://www.stayed.cn/item/24542
转载请注明出处。
本站部分内容来源于网络,如侵犯到您的权益,请 联系我