fork download
  1. <?php
  2.  
  3. $str = '(21)1234-5678';
  4. $substituirIsso = array('-', ')', '(');
  5. $porIsso = array('');
  6. echo str_replace($substituirIsso, $porIsso, $str);
Success #stdin #stdout 0s 82880KB
stdin
Standard input is empty
stdout
2112345678