How to remove all occurrences of a character in a string with PHP

1 Answer

0 votes
$s = "php programming version 7.3.1";
 
$s = str_replace('g', '', $s);  
 
echo $s;
 
  
/*
run:
  
php prorammin version 7.3.1 
     
*/

 



answered Feb 2, 2019 by avibootz
...