fork(32) download
  1. <?php
  2.  
  3. $str = "1  \r\n2";
  4. $new_str = preg_replace("/\s+/u", " ", $str);
  5. echo $new_str;
Success #stdin #stdout 0s 52488KB
stdin
Standard input is empty
stdout
1 2