ucwords() in laravel collection for uppercase code example Example: php function to convert string to camelcase echo ucwords("hello world");