PHP: Convert Underscore/Dash String into camelCase

`Here we created a useful PHP function which can convert Underscored or Dashed String into Camel Case string. In Many cases you might need a function to convert a part of the URL into the name of Controller Class that would be handling the request in MVC Pattern.

Source Code:

function toCamelCase($value){
	$value = ucwords(str_replace(array('-', '_'), ' ', $value));
	$value = str_replace(' ', '', $value)
	return lcfirst($value);

Output / Usage:

$string = "i_like_eduzip";

echo toCamelCase($string); \\it returns iLikeEduzip

$string2 = "i-like-eduzip";

echo toCamelCase($string2); \\it returns iLikeEduzip

$string3 = "i like eduzip";

echo toCamelCase($string3); \\it returns iLikeEduzip

Comments: (Your feedback is valuable to us)