Closed Art4 closed 10 years ago
I've simply added the line return $this; in some Parser methods for method chaining like this:
return $this;
Parser
$parser = new JBBCode\Parser(); ->addCodeDefinitionSet(new JBBCode\DefaultCodeDefinitionSet()) ->addCodeDefinitionSet(new SpecialCodeDefinitionSet()); $text = "The bbcode in here [b]is never closed!"; print $parser->parse($text)->getAsBBCode(); $text = "[u]Another bbcode example![/u]"; print $parser->parse($text)->getAsHtml();
I also fixed the documentation in Parser for some methods.
I've simply added the line
return $this;
in someParser
methods for method chaining like this:I also fixed the documentation in
Parser
for some methods.