PHP Case Functions String

PHP Case Functions

This function help you to convert the case of a string.This capability is not particularly useful for the sample application, but we’ll look at some brief examples.

 

Function Description Use Output
strtoupper() Turns string to uppercase strtoupper($subject) THIS OUTPUT STRING
strtolower() Turns string to lowercase strtolower($subject) this output string
ucfirst() Capitalizes first character of string if it’s alphabetic ucfirst($subject) This output string
ucwords() Capitalizes first character of each word in the string that begins with an alphabetic character ucwords($subject) This Output String

How To Use

 To using this function you are only call function and get object text like this :

  1. $subject = "This Output Sting";
  2. echo "<br>";
  3. echo "strtoupper() = ".strtoupper($subject)."<br>";
  4. echo "ucfirst() = ".ucfirst($subject)."<br>";
  5. echo "ucwords() = ".ucwords($subject)."<br>";

Posted by admin   @   25 October 2009

1 Comments

Comments
Trackbacks to this post.
Leave a Comment

Name

Email

Website

Previous Post
« Top Ajax CMS (Content Management System)
Next Post
CSS manipulation | crate spreadsheet form using css »
Powered by Wordpress   |   Lunated designed by ZenVerse
Top Footer