waiwai933 Posted December 13, 2008 Share Posted December 13, 2008 How do you write a script that takes however many number of spaces, and simplifies it to become one space? Link to comment https://forums.phpfreaks.com/topic/136791-solved-reducing-of-spaces/ Share on other sites More sharing options...
corbin Posted December 13, 2008 Share Posted December 13, 2008 preg_replace('([ ]+)', ' ', $str); Link to comment https://forums.phpfreaks.com/topic/136791-solved-reducing-of-spaces/#findComment-714412 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.