Ok, I've got a drupal install, with a fairly basic zen sub-theme. I have no ajax modules installed. I've installed CKEditor 3.3 correctly according to the WYSIWYG.module instructions. Editing with firefox 3.6 on linux.

When I edit a page with CKeditor, the editor appears to be working fine - I can edit the text, and format it, and copy to and from the editor.

But when I save the node, it saves with nothing in the body (for new nodes), or exactly the same as before I began editing (for existing nodes with content). Also, when I "disable rich text editor" the page reverts to it's previous state, and re-enabling the rich text editor brings back the page in it's un-edited state. Seems very much like the editor isn't writing to the text area at all.

The only thing in the editor itself that doesn't appear to work is the "source" button, which greys out after pressed, and doesn't show the source, although this behaviour seems to be intermittent, and may be unrelated.

The errors I'm getting in firefox are:

Error: Q.attributes._cke_title is undefined
Source File: http://localhost/drupal7/sites/all/libraries/ckeditor/ckeditor.js?l3s73d
Line: 54

Error: uncaught exception: [CKEDITOR.editor] The instance "edit-body-und-0-value" already exists.

Comments

twod’s picture

Status: Active » Postponed (maintainer needs more info)

The synchronization of the editor contents back to the original textarea is done by CKEditor when Wysiwyg calls its .destroy() method. It does this when the form is submitted or the Disable rich text editing link is clicked. If there's a problem with syncing, it's likely inside CKEditor itself.

When exactly do you get that error? If it's when re-enabling the editor, it suggests its shutdown procedures didn't complete, maybe due to an error in itself or some other code which gets triggered by those events.

Does this still happen if you uncheck all buttons and plugins so the editor returns to its default state?

Are you using a custom theme? If so, does it work when using the default theme?

I'm to tired to try to reproduce and debug this myself tonight, so I'll have to get back to you as soon as I can get this done. Any and all info you can provide about the issue in the mean time is appreciated.

naught101’s picture

The error occurs when disabling the editor. the first error occurs the first time, and the second error occurs the second time. Errors don't happen after that, but it still doesn't work.

Yes, this happens with an unadulterated CKEditor profile.

Like I said, I'm using a zen sub theme, but yes, this happens in garland too.

It seems to work if the content is small and simple (like one line, no formatting), but not after the error has occurred.

Even after the error has occurred, if the node is edited without the rich text editor, and then switched back to the rich text editor, then the changes come accross, but not the other way.

I will try re-installing CKeditor soon, see if that helps.

cha0s’s picture

Same here. Have not investigated too much at this point.

It happens when I paste text from a program called AbiWord into CKEditor. AbiWord is kinda like a pared down OpenOffice kind of thing,

TC44’s picture

Happens here also pasting from OpenOffice using the Paste from Word feature with CKEditor, but I'm using July 11 version 6.x-2.x-dev.

chiebert’s picture

Not sure if this helps, but I was having the same problem just now (with wysiwyg 6.x-2.x-dev, and latest ckeditor library, 3.4.something). Was bashing my head against the screen when I suddenly realised my cats had snuck in and installed the ckeditor.module on top of the wysiwyg.module. Doh! Anyhow - I disabled the ckeditor.module, confirmed my wysiwyg profiles were set up the way I really wanted them, and voilá! Wysiwyg/CKEditor-enabled fields properly save without errors. I also revoked my cats' administrative permissions...

sun’s picture

Category: bug » support
Priority: Critical » Normal
Status: Postponed (maintainer needs more info) » Fixed

#5 contains the solution.

Apparently, this means you installed CKEditor module after Wysiwyg, because we already do:

/**
 * Implementation of hook_enable().
 */
function wysiwyg_enable() {
  // Disable conflicting, obsolete editor integration modules whenever this
  // module is enabled. This is crude, but the only way to ensure no conflicts.
  module_disable(array(
    'editarea',
    'editonpro',
    'editor',
    'fckeditor',
    'freerte',
    'htmlarea',
    'htmlbox',
    'jwysiwyg',
    'markitup',
    'nicedit',
    'openwysiwyg',
    'pegoeditor',
    'quicktext',
    'tinymce',
    'tinymce_autoconf',
    'tinytinymce',
    'whizzywig',
    'widgeditor',
    'wymeditor',
    'xstandard',
    'yui_editor',
  ));
}
twod’s picture

Umm, actually 'ckeditor' is not in that array, so Wysiwyg could have been installed after it. It was the latest editor to get in, and I guess we overlooked disabling the other module.

sun’s picture

Good spot! Fixed in all branches. (sorry, forgot to create a patch)

yktdan’s picture

Version: 7.x-2.x-dev » 6.x-2.1
Component: Editor - CKeditor » Editor - TinyMCE

Same problem with TinyMCE in http://drupal.org/node/824710

sun’s picture

Version: 6.x-2.1 » 7.x-2.x-dev
Component: Editor - TinyMCE » Editor - CKeditor

@yktdan: You linked to this issue. And this issue is about CKEditor only.

yktdan’s picture

Status: Fixed » Active

Ok, I installed CKeditor as well as TinyMCE. Same general problem. If I enter text in disabled mode it does not appear when I enable. In TinyMCE I can enter text while enabled, in CKeditor the text block is locked (can't put cursor there). In TinyMCE the entered just disappears when you submit or disable. Couldn't try this in CKeditor because couldn't enter text at all. In TinyMCE, Filetered text works. Haven't tried that in CKeditor.

yktdan’s picture

Problem found. Wysiwyg image module interferes.

sun’s picture

Component: Editor - CKeditor » Code
Status: Active » Fixed

Looks like wysiwyg_image module is the cause. Thus, nothing to fix here.

sun’s picture

Component: Code » Editor - CKEditor

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.