mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Changed bbcode line break support to support paragraphs too
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.1.0@42272 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
e85f057e11
commit
534be77a3b
@ -97,6 +97,8 @@ class BBCodeParser extends TextParser {
|
||||
|
||||
function parse() {
|
||||
$this->content = str_replace(array('&', '<', '>'), array('&', '<', '>'), $this->content);
|
||||
$this->content = "<p>".$this->content."</p>";
|
||||
$this->content = str_replace("\n\n", "</p><p>", $this->content);
|
||||
$this->content = str_replace("\n", "<br />", $this->content);
|
||||
return HTML_BBCodeParser::staticQparse($this->content);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user