joined:Mar 22, 2008
I am trying remove any characters from the beginning
of the string, except for letters A-Z and a-z. In other words, I need to make sure that the string begins with a letter.
Regular Expressions are not my strength by any stretch of the imagination, but here's what I've managed to hack up so far.
$str = preg_replace( "/^[^A-Za-z]*/", '', $str );
For some reason it isn't removing the characters. Any thoughts?