public function processText(string $text): string
    {
        $text = str_replace("<br>", "", $text);
        $text = str_replace("<br/>", "", $text);
        $text = str_replace("<br />", "", $text);
        $text = str_replace("\n", "<br>", $text);
        $text = str_replace("\t", "&nbsp; &nbsp; &nbsp;", $text);

        return preg_replace($this->pattern, $this->replace, $text);
    }
public function processText(string $text): string
    {
        $text = str_replace("<br>", "", $text);
        $text = str_replace("<br/>", "", $text);
        $text = str_replace("<br />", "", $text);
        $text = str_replace("\n", "<br>", $text);
        $text = str_replace("\t", "&nbsp; &nbsp; &nbsp;", $text);

        return preg_replace($this->pattern, $this->replace, $text);
    }
public function processText ( string $ text ) : string { $ text = str_replace ( "<br>" , "" , $ text ) ; $ text = str_replace ( "<br/>" , "" , $ text ) ; $ text = str_replace ( "<br />" , "" , $ text ) ; $ text = str_replace ( "\n" , "<br>" , $ text ) ; $ text = str_replace ( "\t" , "&nbsp; &nbsp; &nbsp;" , $ text ) ; return preg_replace ( $ this -> pattern , $ this -> replace , $ text ) ; }
Process text -> convert BBCode to HTML

@param string $text
@return string
Process text - > convert BBCode to HTML