Well lets see here. What you want done will require the use of regular expression matching, and there are two regular expression functions that you can use... ereg_replace() and preg_replace() If are a Perl developer like me, you should use the latter (the latter was introduced late in PHP3). Here's what you can do with ereg_replace()...
<?php //PHP regular expression replacing...
$stringOfText = "300 elephants are not equal to 100"; //The string of text
$newString = ereg_replace("[[:alpha:]]", "", $stringOfText);
?>
AND here is what you can do with preg_replace()
<?php //Perl regular expression replacing...
$stringOfText = "300 elephants are not equal to 100"; //The string of text
$newString = preg_replace("/\W|\d/", "", $stringOfText);
?>
both of these examples take the string "300 elephants are not equal to 100" and change it to "elephantsarenotequalto".
I know, O LORD, that a man's life is not his own; it is not for man to direct his steps.
Jeremiah 10:23