I have a string which is combination of letters and digits. For my application i have to separate a string with letters and digits: ex:If my string is \"12jan\" i hav to ge
$numbers = preg_replace('/[^0-9]/', '', $str); $letters = preg_replace('/[^a-zA-Z]/', '', $str);