|
|
Tutorials » Php »
|
Topic |
What is ucwords Function?
|
|
Explanation |
|
In PHP, this function converts the first character of each word in a string to uppercase.
Syntax:
ucwords(string)
In the above syntax "string" is the input in which first character of each word is converted to uppercase.
Example:
<?php
echo ucwords("hi how are you!");
?>
Result:
Hi How Are You!
In the above example first letter of all the words of the string is converted to uppercase.
|
|
A Note |
Learn PHP programming language tutorial with simple and neat example. Hope you enjoy this free tutorial.
Do give us your valuable feedback and suggestions on this online tutorial. This is a Copyright Content.
|
|
|
|