2010-07-18 21 views
1

Je tente d'installer CKeditor sur Kohana 2. J'ai déposé le dossier ckeditor dans libraries/et j'ai placé ckeditor.php à côté du dossier ckeditor dans les bibliothèques /. J'essaie d'appeler ckeditor dans mon contrôleur avec les éléments suivants:Problèmes d'installation de CKeditor dans Kohana (v2)

$this->ckeditor = new Ckeditor('FCKEDITOR1'); 
$this->ckeditor->BasePath = 'application/libraries/ckeditor/'; 
$this->ckeditor->value = 'This is some <strong>sample text</strong>.' ; 
$this->ckeditor->create(); 

Je reçois l'erreur et de la difficulté à résoudre le suivant:

Fatal error: Call to undefined method CKEditor::create() in [path redacted]/app-admin/controllers/blog.php on line 18

Répondre

3

bien son simple: il n'y a une telle fonction dans la classe CKEditor.

trouvé aussi dans ce commentaire:

* Example 1: get the code creating %CKEditor instance and print it on a page with the "echo" function. 

* $CKEditor = new CKEditor(); 
* $CKEditor->returnOutput = true; 
* $code = $CKEditor->editor("editor1", "<p>Initial value.</p>"); 
* echo "<p>Editor 1:</p>"; 
* echo $code;