<?php $phone = preg_replace( '/\s+/', '', "01234 567890" ); echo $phone;
<?php $stripped = str_replace(' ', '', "10 1000 0000 000"); echo $stripped;
$str = "\n\n\nHello World!\n\n\n"; echo "With trim: " . trim($str);
$string = preg_replace('/\s+/', '', $string);
{{ \Illuminate\Support\Str::limit($productVal, 20, $end='...') }}