- Posts: 90
COMMUNITY FORUM
JCE editor problems
- Jock
-
Topic Author
- Offline
- Premium Member
I recently re-installed Joomla (so I had the latest version) and then K2 followed by JCE. But for some reason all existing items are missing the JCE editor. The extra fields have no editor and the main content area has no embedded editor.
When I go to create a new item the editor is there and works fine. But when I go back to edit it the editor is not there?
Any ideas on what is going on here and how I can fix this?
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
Please Log in or Create an account to join the conversation.
- Jock
-
Topic Author
- Offline
- Premium Member
- Posts: 90
Or are you talking about another JCE forum?
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
Here is the fix I have sent to the K2 team:Open view.html.php in administrator/components/com_k2/views/items/view.html.phpReplace :
$js = "function initExtraFieldsEditor(){ $$('.k2ExtraFieldEditor').each(function(element) { var id = element.id; if (typeof JContentEditor != 'undefined') { if (tinyMCE.get(id)) { tinymce.EditorManager.remove(tinyMCE.get(id)); } tinyMCE.execCommand('mceAddControl', false, id); } else { new nicEditor({fullPanel: true, maxHeight: 180, iconsPath: '".JURI::root()."administrator/components/com_k2/images/system/nicEditorIcons.gif'}).panelInstance(element.getProperty('id')); } }); } function syncExtraFieldsEditor(){ $$('.k2ExtraFieldEditor').each(function(element){ editor = nicEditors.findEditor(element.getProperty('id')); if(typeof editor != 'undefined'){ editor.saveContent(); } }); } ";
with :
$js = "function initExtraFieldsEditor(){ $$('.k2ExtraFieldEditor').each(function(element) { if (typeof JContentEditor != 'undefined') { // wait until main editor is added tinyMCE.onAddEditor.add(function(mgr, ed) { // skip for extrafields editor if (ed.id == element.id) { return; } // wait until main editor is initialized ed.onInit.add(function() { tinyMCE.execCommand('mceAddEditor', false, element); }); }); } else { new nicEditor({fullPanel: true, maxHeight: 180, iconsPath: '".JURI::root()."administrator/components/com_k2/images/system/nicEditorIcons.gif'}).panelInstance(element.getProperty('id')); } }); } function syncExtraFieldsEditor(){ $$('.k2ExtraFieldEditor').each(function(element){ editor = nicEditors.findEditor(element.getProperty('id')); if(typeof editor != 'undefined'){ editor.saveContent(); } }); } ";
Please Log in or Create an account to join the conversation.
- Jock
-
Topic Author
- Offline
- Premium Member
- Posts: 90
That code doesn't even exist in that file for me?
Please Log in or Create an account to join the conversation.
- Jock
-
Topic Author
- Offline
- Premium Member
- Posts: 90
administrator/components/com_k2/views/item/view.html.php
Notice the path is item and not items
Anyway, I think we are onto something here because this file doesn't look right to me. I edited it once uploaded it with your changes and the editor loaded on the content area but only the very 1st extra field had a JCE editor and the other fields didnt.
When I look at this line:
for($i=0; $i<sizeof($extraFields); $i++){ $extraFields[$i]->element=$extraFieldModel->renderExtraField($extraFields[$i],$item->id); }
Parts of it are also orange (in dreamweaver), which signifies to me that something is wrong with this file somewhere and that part is being commented out somehow?
Please Log in or Create an account to join the conversation.
- Jock
-
Topic Author
- Offline
- Premium Member
- Posts: 90
Definitely something wrong with that file I feel.
How to troubleshoot?
Is there anywhere I can download older versions of JCE?
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
Try to disable force white background, black text, in JCE. And write here if it helped.
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
I am satisfied with default K2 editor for fields. Don´t need all buttons from JCE.
Search forum, one guy had a solution for JCE and extra fields.
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
But, it depends what you want from extra fields. If you want some videos in fields, then JCE is needed.
Please Log in or Create an account to join the conversation.
- Nick Texidor
-
- Visitor
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
Is there anywhere I can download older versions of JCE?
Here is JCE version that never made problems with K2. 1.5.77
As it is without subscription plugins, i can post it here.
Please Log in or Create an account to join the conversation.
- Jock
-
Topic Author
- Offline
- Premium Member
- Posts: 90
Please Log in or Create an account to join the conversation.
- Jock
-
Topic Author
- Offline
- Premium Member
- Posts: 90
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
JCE is 2.0 Beta7. Can´t even chose editor in field settings. "Use editor" is always empty.
Please Log in or Create an account to join the conversation.
- Jock
-
Topic Author
- Offline
- Premium Member
- Posts: 90
JCE is not being embedded when I 1st go to create an item. Once I save the item and go back in to edit it ... it is there for extra fields. Also when I save something the, the changes doesn't actually take place? If I try and insert an object I get a javascript error in IE8:
Message: '0' is null or not an objectLine: 1Char: 1905Code: 0URI: http://*******/plugins/editors/jce/tiny_mce/plugins/media/editor_plugin.js?version=1577&cid=37
Is there anyway I can download different versions of JCE to test.
Or does anyone have idea why I am having so many problems with JCE?
Please Log in or Create an account to join the conversation.
- Jock
-
Topic Author
- Offline
- Premium Member
- Posts: 90
Still they are not appearing upon when you create a new item
Please Log in or Create an account to join the conversation.