Unix and Linux Discussions Tagged with bar |
|
Thread / Thread Starter |
Last Post |
Replies |
Views |
Forum |
|
|
|
5 |
5,515 |
UNIX for Beginners Questions & Answers |
|
|
|
1 |
2,378 |
Shell Programming and Scripting |
|
|
|
1 |
1,802 |
What is on Your Mind? |
|
|
|
3 |
5,797 |
Shell Programming and Scripting |
|
|
|
0 |
5,337 |
Programming |
|
|
|
0 |
4,276 |
Windows & DOS: Issues & Discussions |
|
|
|
2 |
7,788 |
Shell Programming and Scripting |
|
|
|
0 |
1,278 |
UNIX and Linux RSS News |
|
|
|
0 |
2,237 |
OS X Support RSS |
|
|
|
0 |
951 |
Software Releases - RSS News |
|
|
|
0 |
864 |
Software Releases - RSS News |
|
|
|
0 |
1,485 |
UNIX and Linux RSS News |
|
|
|
1 |
4,933 |
Shell Programming and Scripting |
|
|
|
0 |
1,257 |
Software Releases - RSS News |
|
|
|
0 |
1,434 |
UNIX and Linux RSS News |
|
|
|
1 |
16,061 |
UNIX for Advanced & Expert Users |
|
|
|
0 |
982 |
UNIX and Linux RSS News |
|
|
|
0 |
788 |
Software Releases - RSS News |
|
|
|
0 |
2,062 |
UNIX and Linux RSS News |
|
|
|
1 |
4,518 |
Linux |
|
|
|
0 |
997 |
Software Releases - RSS News |
|
|
|
3 |
5,983 |
Shell Programming and Scripting |
|
|
|
5 |
3,390 |
UNIX for Dummies Questions & Answers |
|
|
|
2 |
3,732 |
UNIX for Advanced & Expert Users |
|
|
|
5 |
3,564 |
UNIX for Dummies Questions & Answers |
|
|
|
3 |
4,624 |
UNIX for Dummies Questions & Answers |
|
|
|
3 |
15,768 |
UNIX for Dummies Questions & Answers |
|
|
|
2 |
6,967 |
UNIX for Dummies Questions & Answers |
UCWORDS(3) 1 UCWORDS(3)
ucwords - Uppercase the first character of each word in a string
SYNOPSIS
string ucwords (string $str)
DESCRIPTION
Returns a string with the first character of each word in $str capitalized, if that character is alphabetic.
The definition of a word is any string of characters that is immediately after a whitespace (These are: space, form-feed, newline, car-
riage return, horizontal tab, and vertical tab).
PARAMETERS
o $str
- The input string.
RETURN VALUES
Returns the modified string.
EXAMPLES
Example #1
ucwords(3) example
<?php
$foo = 'hello world!';
$foo = ucwords($foo); // Hello World!
$bar = 'HELLO WORLD!';
$bar = ucwords($bar); // HELLO WORLD!
$bar = ucwords(strtolower($bar)); // Hello World!
?>
NOTES
Note
This function is binary-safe.
SEE ALSO
strtoupper(3), strtolower(3), ucfirst(3), mb_convert_case(3).
PHP Documentation Group UCWORDS(3)