I am having problems trying to use FCKeditor to load in a external config file containing toolbarsets etc. I have tried this both with the CFC and the custom tag for coldfusion. I get an error the variable I am passing is not a struct.
This is what my code looks like
<cfscript>
fckEditor = createObject("component", "#application.mapping#fckeditor");
fckEditor.instanceName="content";
fckEditor.basePath="../assets/tags/FCKeditor/";
fckEditor.value="#qry_PageContentGet.content#";
fckEditor.width="200";
fckEditor.height="250";
fckEditor.toolbarSet="Basic";
fckEditor.checkBrowser="true";
fckEditor.config="/myconfig.js";
fckEditor.create();
</cfscript>
If I remove the fckEditor.config="/myconfig.js"; I get no error, but obviously it is not loading my external file either. Any help would be appreciated.
Mark
This is what my code looks like
<cfscript>
fckEditor = createObject("component", "#application.mapping#fckeditor");
fckEditor.instanceName="content";
fckEditor.basePath="../assets/tags/FCKeditor/";
fckEditor.value="#qry_PageContentGet.content#";
fckEditor.width="200";
fckEditor.height="250";
fckEditor.toolbarSet="Basic";
fckEditor.checkBrowser="true";
fckEditor.config="/myconfig.js";
fckEditor.create();
</cfscript>
If I remove the fckEditor.config="/myconfig.js"; I get no error, but obviously it is not loading my external file either. Any help would be appreciated.
Mark
RE: config in cfc or coldfusion custom tag
Use:
fckEditor.config = StructNew();
fckEditor.config.CustomConfigurationsPath = '/myconfig.js';
That should do the trick.
RE: config in cfc or coldfusion custom tag