How to use trim() in php!

trim
(PHP 4, PHP 5)

trim — Strip whitespace (or other characters) from the beginning and end of a string