I have this pregmatch which allows for only numeric characters but i need to allow for the potential of one alpha character at the start of the string such as
T17900
$value = preg_replace("/[^0-9\s]/", "", $value);
EXAMPLE:
IF this is my $value = 22202-HAV.jpg
I need only 22202.
If this is my $value = T22202-HAV.jpg
I need only T22202
basically, if the string starts with a letter + some digits or just digits, keep this part and delete the rest.