private static function cleanHTML($output)
    {
        $output = preg_replace('/<title>.*<\/title>/smi', '', $output);
        $output = preg_replace('/<style>.*<\/style>/smi', '', $output);
        $output = strip_tags($output);
        $output = preg_replace('/(\n+)(\s+)/smi', "\n", $output);
        $output = preg_replace('/&nbsp;/smi', ' ', $output);

        return $output;
    }
private static function cleanHTML($output)
    {
        $output = preg_replace('/<title>.*<\/title>/smi', '', $output);
        $output = preg_replace('/<style>.*<\/style>/smi', '', $output);
        $output = strip_tags($output);
        $output = preg_replace('/(\n+)(\s+)/smi', "\n", $output);
        $output = preg_replace('/&nbsp;/smi', ' ', $output);

        return $output;
    }
private static function cleanHTML ( $ output ) { $ output = preg_replace ( '/<title>.*<\/title>/smi' , '' , $ output ) ; $ output = preg_replace ( '/<style>.*<\/style>/smi' , '' , $ output ) ; $ output = strip_tags ( $ output ) ; $ output = preg_replace ( '/(\n+)(\s+)/smi' , "\n" , $ output ) ; $ output = preg_replace ( '/&nbsp;/smi' , ' ' , $ output ) ; return $ output ; }
Remove HTML elements from the error output.

@param string $output

@return string
Remove HTML elements from the error output .