Page 1 of 1

CMSimple-Scripting with FCKeditor4CMSimple

Posted: Sat Oct 18, 2008 10:34 am
by Holger
Hi folks!

In some cases FCKeditor can't save your inserted CMSimple scripting code correct.
If you edit a page with a script in wysiwyg-mode, the editor replaces all special characters
to their htmlentities.

Here's an easy solution to save your code in FCKeditor:

Open the configuration file ./FCKeditor/custom_configurations/fckconfig_cmsimple.js

Search for the line:

Code: Select all

FCKConfig.ProtectedSource.Add( /<\?[\s\S]*?\?>/g ) ;    // PHP style server side code
and add below:

Code: Select all

FCKConfig.ProtectedSource.Add( /#CMSimple[\s\S]*?#/g) ; // CMSimple scripting
Be sure to save the file in UTF-8 without BOM - mode (use Notepad++ for example).
Clear your browser's cache and login to CMSimple.

From now CMSimple-Scripts are invisible and protected in wysiwyg mode.
Switch to html-mode to edit or insert a script and save in html-mode.
That's it :)

Of course we'll integrate that in the next version of FCKeditor4CMSimple.

Holger

Re: CMSimple-Scripting with FCKeditor4CMSimple

Posted: Mon Oct 20, 2008 7:01 pm
by Connie
Holger,

bravo!