Fix charset management with ace
This commit is contained in:
parent
687ccbfa10
commit
64c4f899f3
@ -63,7 +63,7 @@ class DolEditor
|
||||
* @param string $cols Size of cols for textarea tool (textarea number of cols '70' or percent 'x%')
|
||||
* @param int $readonly 0=Read/Edit, 1=Read only
|
||||
*/
|
||||
function __construct($htmlname,$content,$width='',$height=200,$toolbarname='Basic',$toolbarlocation='In',$toolbarstartexpanded=false,$uselocalbrowser=true,$okforextendededitor=true,$rows=0,$cols=0,$readonly=0)
|
||||
function __construct($htmlname, $content, $width='', $height=200, $toolbarname='Basic', $toolbarlocation='In', $toolbarstartexpanded=false, $uselocalbrowser=true, $okforextendededitor=true, $rows=0, $cols=0, $readonly=0)
|
||||
{
|
||||
global $conf,$langs;
|
||||
|
||||
@ -121,7 +121,7 @@ class DolEditor
|
||||
$this->editor->Config['SkinPath'] = DOL_URL_ROOT.'/theme/'.$conf->theme.'/fckeditor/';
|
||||
}
|
||||
}
|
||||
|
||||
var_dump($content);exit;
|
||||
// Define some properties
|
||||
if (in_array($this->tool,array('textarea','ckeditor','ace')))
|
||||
{
|
||||
@ -282,11 +282,10 @@ class DolEditor
|
||||
$out.= ($this->height?' height: '.$this->height.'px; ':'');
|
||||
//$out.=" min-height: 100px;";
|
||||
$out.= '">';
|
||||
/*$out.= preg_replace(array('/^<\?php/','/\?>$/'), array('<?php','?>'), $this->content); */
|
||||
$out.= htmlentities($this->content);
|
||||
$out.= htmlspecialchars($this->content);
|
||||
$out.= '</pre>';
|
||||
$out.= '<textarea id="'.$this->htmlname.'" name="'.$this->htmlname.'" style="width:0px; height: 0px; display: none;">';
|
||||
$out.= htmlentities($this->content);
|
||||
$out.= htmlspecialchars($this->content);
|
||||
$out.= '</textarea>';
|
||||
|
||||
$out.= '<script type="text/javascript" language="javascript">'."\n";
|
||||
|
||||
Loading…
Reference in New Issue
Block a user