Re: Making a string title case ?
| From: | Philip Olson | Date: | Sun, 24 Jun 2001 15:35:11 +0000 |
| Subject: | Re: Making a string title case ? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-55029@lists.php.net to get a copy of this message | ||
And if you want :
$str = 'This is a STRING!';
To turn into :
$str = 'This Is A String!';
Then do :
$str = ucwords(strtolower($str));
Regards,
Philip
On Sat, 23 Jun 2001, Data Driven Design wrote:
> Use the ucwords() function
>
> http://www.php.net/manual/en/function.ucwords.php
>
> Data Driven Design
> P.O. Box 1084
> Holly Hill, Florida 32125-1084
>
> http://www.datadrivendesign.com
> http://www.rossidesigns.net
> ----- Original Message -----
> From: Jason Katz-Brown <jason@katzbrown.com>
> To: <php-general@lists.php.net>
> Sent: Saturday, June 23, 2001 1:46 PM
> Subject: [PHP] Making a string title case ?
>
>
> > Hi
> >
> > Whats the best way to make $string title case? In other words, turn "this
> is
> > a string" into "This Is A String" ?
> >
> > Thanks a bunch
> >
> > Jason
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> > For additional commands, e-mail: php-general-help@lists.php.net
> > To contact the list administrators, e-mail: php-list-admin@lists.php.net
> >
> >
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> For additional commands, e-mail: php-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
>