/** * Initializes tinyMCE **/ function initTinymce() { $this->config["elements"] = $this->getName() . '_tarea'; $this->config["language"] = $this->getLanguage(); $this->config["rootpath"] = $this->rootpath; $this->config["area_width"] = $this->_width; $this->config["area_height"] = $this->_height; $this->config["fonts"] = $this->getFonts(); //$this->config["file_browser_callback"] = "ajaxfilemanager"; /*$this->config["callback"] = 'function ajaxfilemanager(field_name, url, type, win) { var ajaxfilemanagerurl = "../../../../../editors/tinymce/jscripts/plugins/ajaxfilemanager/ajaxfilemanager.php"; switch (type) { case "image": break; case "media": break; case "flash": break; case "file": break; default: return false; } tinyMCE.activeEditor.windowManager.open({ url: ajaxfilemanagerurl, width: 782, height: 440, inline : "yes", close_previous : "no" },{ window : win, input : field_name }); /* return false; var fileBrowserWindow = new Array(); fileBrowserWindow["file"] = ajaxfilemanagerurl; fileBrowserWindow["title"] = "Ajax File Manager"; fileBrowserWindow["width"] = "782"; fileBrowserWindow["height"] = "440"; fileBrowserWindow["close_previous"] = "no"; tinyMCE.openWindow(fileBrowserWindow, { window : win, input : field_name, resizable : "yes", inline : "yes", editor_id : tinyMCE.getWindowArg("editor_id") }); return false; }';*/ require_once dirname(__FILE__) . "/tinymce.php"; $this->tinymce = TinyMCE::instance($this->config); }