How can I remove everything from a string apart from letters? I have an input field for first names.
In PHP, you can use (as suggested by @rczajka and @mario):
preg_replace('/PL/u', '', $str)
Working Example: http://codepad.viper-7.com/V78skl
You may want to checkout this Tutorial for regex
1.4m articles
1.4m replys
5 comments
57.0k users