 <p>If the parts to remove are always the same you can use <code>str_replace()</code> function passing as serach value an array with both parts you want to remove</p> <pre><code>function remove_strings($string) { return str_replace(array('LifeSteal ', ' \n'), '', $string); } </code></pre>