#781 Plain text dashlet shown on one single line

SVN:trunk[2875]
This commit is contained in:
Romain Quetiez
2013-10-03 15:40:45 +00:00
parent 894b59eee1
commit 169f576ccf

View File

@@ -355,6 +355,7 @@ class DashletPlainText extends Dashlet
public function Render($oPage, $bEditMode = false, $aExtraParams = array())
{
$sText = htmlentities($this->aProperties['text'], ENT_QUOTES, 'UTF-8');
$sText = str_replace(array("\r\n", "\n", "\r"), "<br/>", $sText);
$sId = 'plaintext_'.($bEditMode? 'edit_' : '').$this->sId;
$oPage->add('<div id="'.$sId.'" class="dashlet-content">'.$sText.'</div>');