PHP to strip whitespace and extraneous characters

How can I write a PHP function to strip out any space, commas, apostrophies, etc from the string? I just want the string to be left with only alphabet characters only.

preg_replace( '/[^a-zA-Z]+/', '', $str )