I am getting the following errors when trying to load fckeditor into Firefox 1.0 (which I installed two weeks ago). Everything works fine in IE. In firefox the formatted text shows up but the toolbar doesn't. The javascript console flags the last entry for the ToolbarSets array, no matter what it is.
Error: FCKConfig.ToolbarSets has no properties
Error: FCKConfig.FontColors has no properties
Here is how I am calling the object:
<script type="text/javascript">
window.onload = function() {
var oFCKeditor = new FCKeditor('f_body', 450, 425, 'ICR') ;
oFCKeditor.ReplaceTextarea() ;
}
</script>
And here is my config:
FCKConfig.ToolbarSets["ICR"] = [
['Source','-','Save','NewPage','Preview'],
['Cut','Copy','Paste','PasteText','PasteWord'],
['Undo','Redo','-','Find','Replace','-','SelectAll','RemoveFormat'],
['Bold','Italic','Underline','StrikeThrough','-','Subscript','Superscript'],
['OrderedList','UnorderedList','-','Outdent','Indent'],
['JustifyLeft','JustifyCenter','JustifyRight','JustifyFull'],
['Link','Unlink'],
['Image','Table','Rule','SpecialChar'],
['FontFormat','FontSize'],
['TextColor','BGColor']
] ;
Error: FCKConfig.ToolbarSets has no properties
Error: FCKConfig.FontColors has no properties
Here is how I am calling the object:
<script type="text/javascript">
window.onload = function() {
var oFCKeditor = new FCKeditor('f_body', 450, 425, 'ICR') ;
oFCKeditor.ReplaceTextarea() ;
}
</script>
And here is my config:
FCKConfig.ToolbarSets["ICR"] = [
['Source','-','Save','NewPage','Preview'],
['Cut','Copy','Paste','PasteText','PasteWord'],
['Undo','Redo','-','Find','Replace','-','SelectAll','RemoveFormat'],
['Bold','Italic','Underline','StrikeThrough','-','Subscript','Superscript'],
['OrderedList','UnorderedList','-','Outdent','Indent'],
['JustifyLeft','JustifyCenter','JustifyRight','JustifyFull'],
['Link','Unlink'],
['Image','Table','Rule','SpecialChar'],
['FontFormat','FontSize'],
['TextColor','BGColor']
] ;
RE: RC2 Not working with Firefox 1.0
Do you have a toolbarset called "default". If you don't the system can not find a toolbar.
I don't know how they do it in JS - but in my php I do it like this:
In the "file":
$oFCKeditor = new FCKeditor('tagwallsubtext') ;
$oFCKeditor->BasePath = '/siteadm/fck/' ;
$oFCKeditor->ToolbarSet = 'Tagwall' ;
$oFCKeditor->Width = '50%' ;
$oFCKeditor->Height = '150' ;
$oFCKeditor->Value = '' ;
$oFCKeditor->Create() ;
In the FCKconfig.js:
FCKConfig.ToolbarSets["Tagwall"] = [
['Bold','Italic','-','Smiley']
] ;
I hope this helped.
RE: RC2 Not working with Firefox 1.0
I didn't realize I could use php to build the editor. Perhaps i'll do that instead.
RE: RC2 Not working with Firefox 1.0
var when you instantiate an instance(ct?)... haven't tested thoroughly (cache issues or not), but that's an option for dynamic configurations... Toolbar sets, etc..
For CF it's:
<cfscript>
customConfig = structNew();
customConfig["CustomConfigurationsPath"] = '/FCKeditor/customConfig.js';
fckEditor = createObject("component", "/FCKeditor/fckeditor");
fckEditor.instanceName = "textEditor";
fckEditor.value = '#getPage.pageText#';
fckEditor.basePath = "/fckeditor/";
fckEditor.width = "100%";
fckEditor.height = 500;
fckEditor.toolBarSet = 'PluginTest';
fckEditor.config = customConfig;
fckEditor.create(); // create the editor.
</cfscript>
For PHP it would be something quite similar, I assume.
Yay for FCK!
RE: RC2 Not working with Firefox 1.0
yeah, that's correct. A bit annoying but.. I'd prefer that than IE
RE: RC2 Not working with Firefox 1.0
Everytime you change something in the /fckeditor/ folder... Clear the damn cache...
RE: RC2 Not working with Firefox 1.0
It may have been something else. When I unzipped the files they were saved in the dos format. When I opened them up in vim on my linux server there were ^M characters all over the place. I had modified fckconfig.js in homesite which I have configured to save the files in the unix format (\n for line breaks). I opened up fckeditor.js in homesite and saved it as a unix file and now everything works fine. I'm guessing firefox didn't like the mismatched formats?
RE: RC2 Not working with Firefox 1.0
RE: RC2 Not working with Firefox 1.0
I have been getting undefined message nothing more...
Butin IE 6 sp2 there is no error
RE: RC2 Not working with Firefox 1.0
I solved this problem by removing the 'Styles' button out of the default toolbar.
So it seems there is an issue with the 'Styles' selector on Firefox when the site is being served off a Linux server. Very strange. If anybody has a fix for this please let me know!