From 05ff0c7f0bcefd487d88e0901737408a29477753 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 22 Mar 2012 00:09:05 +0100 Subject: [PATCH] New: Can add more js when creating editor. --- htdocs/core/class/doleditor.class.php | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/htdocs/core/class/doleditor.class.php b/htdocs/core/class/doleditor.class.php index ad536443502..e26e68ee6c1 100644 --- a/htdocs/core/class/doleditor.class.php +++ b/htdocs/core/class/doleditor.class.php @@ -138,10 +138,11 @@ class DolEditor * Output edit area inside the HTML stream. * Output depends on this->tool (fckeditor, ckeditor, texatrea, ...) * - * @param int $noprint 1=Return HTML string instead of printing it to output + * @param int $noprint 1=Return HTML string instead of printing it to output + * @param string $morejs Add more js. For example: "editor.on( \'saveSnapshot\', function(e) { alert(\'ee\'); });" * @return void */ - function Create($noprint=0) + function Create($noprint=0,$morejs='') { global $conf; @@ -172,7 +173,7 @@ class DolEditor $out.= ''; } }