/** * Remove surrounding <p></p> blocks * input: <p ...><!-- ... --></p>...<p ...><!-- ... --></p> * output: <!-- ... -->...<!-- ... --> */ public static function removeSurroundingPBlocks(&$string) { if (empty($string)) { return; } RLText::removeStartingPTag($string); RLText::removeEndingPTag($string); }