first leter to caps php code example
Example 1: first character uppercase php
ucwords("hello world"); // Hello World
ucfirst("hello world"); // Hello world
Example 2: ucfirst
<?php
/* Convert the first character of "hello" to uppercase: */
echo ucfirst("hello samy!");
//output : Hello samy!
?>