<?php $str = "Sorry that meant to say hungover and feeling sorry for myself. 😩"; $pattern = '/((?=:)|(?=;))(.*)(?=\s{1,})/i'; $str = preg_replace($pattern, '', $str); echo $str;
You have javascript disabled. You will not be able to edit any code.