Bug #15286 Updated: ucwords doesn't work with capitalized string
| From: | philip@php.net | Date: | Tue, 29 Jan 2002 23:15:16 +0000 |
| Subject: | Bug #15286 Updated: ucwords doesn't work with capitalized string | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-78479@lists.php.net to get a copy of this message | ||
ID: 15286
Updated by: philip
Old Summary: ucwords doesn't work with capitalized string
Reported By: jim_ekleberry@hotmail.com
Old Status: Open
Status: Bogus
Bug Type: Strings related
Operating System: Win2K SP2
PHP Version: 4.1.1
New Comment:
This is expected behavior, not a bug.
$str = 'McDonalds';
You want ucwords($str) to result in Mcdonalds? If so, use strtolower()
first as the documentation suggests.
Previous Comments:
------------------------------------------------------------------------
[2002-01-29 17:44:56] jim_ekleberry@hotmail.com
$propercompany = ucwords("WOLF PACK TRADERS");
$propercompany should be "Wolf Pack Traders"
I am running PHP v4.1.1 with:
System Windows NT 5.0 build 2195
Build Date Dec 30 2001
Server API CGI
Virtual Directory Support enabled
Configuration File (php.ini) Path C:\WINNT\php.ini
ZEND_DEBUG disabled
Thread Safety enabled
And using IIS 5.0
I know that this problem is mentioned in the documentation but I did
not find an actual bug report when I searched the bug database to
actually have it fixed.
Jim Ekleberry
------------------------------------------------------------------------
Edit this bug report at http://bugs.php.net/?id=15286&edit=1