Hyvor Developer
  Home   Download   Copy
Code
<?php
$str = 'Hello World';
$regex = '/\s/';
echo preg_replace($regex, '', $str);
Result