chantown Posted March 18, 2008 Share Posted March 18, 2008 Hi, Let's say I have a string: abc = "The fox's tail & legs were big!!!@"; How do make abc so that it removes EVERY symbol but the alphabets and the spaces? to "The foxs tail legs were big" Thanks! Link to comment https://forums.phpfreaks.com/topic/96665-strings-command/ Share on other sites More sharing options...
chantown Posted March 18, 2008 Author Share Posted March 18, 2008 Nevermind, i got it! preg_replace( "#[^a-zA-Z0-9 ]#", "", $input); Link to comment https://forums.phpfreaks.com/topic/96665-strings-command/#findComment-494666 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.