php remove dashes from string

Solutions on MaxInterview for php remove dashes from string by the best coders in the world

showing results for - "php remove dashes from string"
Iyanna
01 Apr 2018
1//replace dashes (-) with spaces ( )  
2$string="text-with-dashes";
3//php string replace
4$test = str_replace("-", " ", $string);