fckedit - QuickCMS 2.0

papakilo

No avatar

2008-01-31 00:41

How do I insert fckedit in quick.cms all of the posts say the instructions are in the tips, but there is nothing in the tips about fckedit

» Quick.Cms v2.x

treewood (OpenSolution)

Avatar: treewood

2008-01-31 08:24

Please read this:
http://opensolution.org/Quick.Cms/docs_v1.x/?id=tips

papakilo

No avatar

2008-01-31 16:07

I did everything that I could from there and still get
Fatal error: Call to undefined function htmlEditor() in C:\Websites\test\actions_admin\p.php on line 62

How do I fix this?

treewood (OpenSolution)

Avatar: treewood

2008-02-01 09:46

papakilo - very strange ... you should have htmlEditor function in plugins/edit/htmleditor.php

papakilo

No avatar

2008-02-03 15:28

I started over and got it to work - somewhat.

If I set the option "WYSWIG editor" to NO it appears as I would expect it to with fckedit on the Full Description, but

If I set "WYSWIG editor" to YES then I get the WYSWIG editor on the Short Description, a narrow width WYSWIG editor on the Full Description and then a normal width FCK editor below the Full Description.

Where in the code should I look to turn off the mini Full Description window?

papakilo

No avatar

2008-02-04 04:18

OK, I found it!

I have the fck editor working for the Full Description and the Short description is set with the "WYSWIG editor" option.

If anyone wants the solution, I will post what I changed.

idaryl

Avatar: idaryl

2008-02-04 08:16

Yes please I would like to have it

papakilo

No avatar

2008-02-04 21:43

This is the way I did it. It is similar to the one in the tips, but several of the indicated changes in tips I couldn't make, because the files or the folders were not there. Also instead of deleting things I prefer to comment them out, just in case I screw up.



1) Download FCKeditor http://www.fckeditor.net (about 2 MB - after unpack)

2) Unpack file on you disc and copy folder to server - to main directory - where you have files "index.php" and "admin.php"

3) Edit file "admin.php" and add following line (best will be beside other functions require_once() )

require_once ( 'fckeditor/fckeditor.php' );

4) Edit file "plugins/edit/htmleditor.php" insert this function after the function htmlEditor() with:

function fckhtmlEditor( $sName = 'tresc', $iH = '300', $iW = '400', $sContent = '' ) {
$oFCKeditor = new FCKeditor($sName) ;
$oFCKeditor->BasePath = 'fckeditor/';
$oFCKeditor->Value = $sContent;
$oFCKeditor->Width = '100%';
$oFCKeditor->Height = $iH;
return $oFCKeditor->CreateHtml();
}

5) edit the file "actions_admin/p.php" change the line

$sDescriptionFull = htmlEditor ( 'sDescriptionFull', '280', '100%', $aData['sDescriptionFull'], Array( 'ToolbarSet' => 'DescriptionFull' ) ) ;

to

$sDescriptionFull = fckhtmlEditor ( 'sDescriptionFull', '280', '100%', $aData['sDescriptionFull'], Array( 'ToolbarSet' => 'DescriptionFull' ) ) ;

6) edit the file "templates/admin/edit.tpl" change the call

tinyMCE.init({
theme : "quick",
mode : "exact",
elements : "sDescriptionShort,sDescriptionFull,sContent",
debug : false
});

to
tinyMCE.init({
theme : "quick",
mode : "exact",
elements : "sDescriptionShort,<!sDescriptionFull,>sContent",
debug : false
});

7) Edit the file "fckeditor/fckconfig.js", find following lines and change asp to php:

var _FileBrowserLanguage = 'php' ;
var _QuickUploadLanguage = 'php' ;

Back to top
about us | contact