ucfirst( ) and ucwords( )

                 ucfirst( ) to convert the first letter of every string to uppercase, and ucwords( ) to convert the first letter of every word in the string to uppercase. These are also take one parameter and return the converted result .

ucfirst($str);

ucwords($str);
ucfirst( )
<?php
$str = "good morning!";
echo ucfirst($str);
?>
Output : Good morning!
ucwords( )
<?php
$str = "good morning!";
echo ucwords($str);
?>
Output : Good Morning!