- preg_replace_callback: documentation ( source)
- strtoupper: documentation ( source)
<?php
$text = "33,abc: A programming language";
$result = preg_replace_callback('/^([^a-z]*)([a-z])/i', function($m)
{
return $m[1].strtoupper($m[2]);
}, $text);
echo $result;