FCKeditor integration |
[eluser]Unknown[/eluser]
hello im trying to integrate FCKeditor in my project but facing some problem i use to the following way to integrate the editor i modified "application/libraries/Fckeditor.php" ----------------------------------------------------------- <?php if (!defined('BASEPATH')) exit('No direct script access allowed'); class Fckeditor { var $InstanceName ; var $BasePath ; var $Width ; var $Height ; var $ToolbarSet ; var $Value ; var $Config ; // PHP 5 Constructor (by Marcus Bointon <[email protected]>) function __construct( $instanceName ) { $this->InstanceName = $instanceName ; $this->BasePath = '/fckeditor/' ; $this->Width = '100%' ; $this->Height = '200' ; $this->ToolbarSet = 'Default' ; $this->Value = '' ; $this->Config = array() ; } // PHP 4 Contructor function Fckeditor( $instanceName ) { $this->__construct( $instanceName ) ; } } ?> ----------------------------------------------------------- and controller file *-----------------------------------------------------------* $this->load->library('fckeditor', 'FCKEDITOR1'); *-----------------------------------------------------------* and view file *-----------------------------------------------------------* <?php $this->fckeditor->BasePath = base_url() .'/plugins/fckeditor/'; $this->fckeditor->ToolbarSet = 'Default'; echo $this->fckeditor->Create() ; ?> *-----------------------------------------------------------* it gives me the following error Fatal error: Call to undefined method Fckeditor::CreateHtml() in another thing in above way to integrate editor i have to follow CI 1.5 or have to keep 1.4 also with that. my CI version is CI 1.6.3 and FCKeditor 2.6.3 waiting for your response, please.
[eluser]BoogieK[/eluser]
Hy, That`s what I finished about 5 minutes ago. It works great. I integrated it in about half day because I had to make some changes to my .htaccess. Anyway, when the erro from CreateHtml() appears to me I realised that the modification of Fckeditor.php file from library was to drastic. I`ve pasted the code from CI 1.5 integration over the fckeditor.php and I deleted all the function from it remaining only the construct function. So take care when you make the changes because the tutorial doesn`t explain all this stuff.
[eluser]umefarooq[/eluser]
hi put this file in you application library folder Fckeditor fckeditor folder should be in your system plugin folder when you call you basepath than it should be like this. Code: $this->load->library('fckeditor','content'); it will work and also working with me.
[eluser]charlie spider[/eluser]
the file you link to gives this >>> No direct script access allowed
[eluser]BoogieK[/eluser]
But you can also get the file from the wiki page. If you need it.
[eluser]riza_nurhadi[/eluser]
FCKeditor works for me too. im using CI 1.6.x. and i got this from some article its in indonesia language. first i modified 'application/libraries/Fckeditor.php' Code: if (!defined('BASEPATH')) exit('No direct script access allowed'); then i modified 'system/plugins/fckeditor/fckeditor_php5.php' Code: //this was the code before modified load in controller Code: $this->load->library('fckeditor',array('instanceName' => 'content','BasePath' => base_url().'system/plugins/fckeditor/','ToolbarSet' => 'Basic','Width'=>'100%','Height'=>'200','Value'=>'')); show it in your view form Code: echo $this->fckeditor->Create() ; getting the value Code: $this->input->post('content');
[eluser]BoogieK[/eluser]
That`s true... FCKeditor works for me too, integrated with CI 1.7. I made some modifications for my needs but if you follow the steps from the Wiki page it will work very good. For CI 1.6 you have to use the FCKeditor integrated with CI 1.5 and create your library, the plugin and the controller. I think that on the Wiki page is a post with something similiar. |
Welcome Guest, Not a member yet? Register Sign In |