(Is this the longest issue title ever? :-) )
Thnx for a way cool module.
Repeatable: always
Situation
Node-outer has node-inner displayed within it. Form-edit-trigger is a form with one button, shown before node-inner (not inside node-inner - form-edit-trigger and node-inner are siblings). Clicking the button replaces form-edit-trigger with form-edit-inner-node, a form for editing the content of inner-node. It's the usual Drupal form for editing content of a node, with all the fields and such.
Click Save button on form-edit-inner-node to save the form's data, and return to the original display - node-outer [ form-edit-trigger node-inner ] .
Works fine w/o CKEditor.
Install CKEditor module and configure it.
Show node-outer as before. Click the form-edit-trigger button. Display is as expected. The body field in form-edit-inner-node shows with CKEditor handling content editing. Click Save, and... WSOD! (Because JS code crashed, and left freeze-height
displayed.)
Fix
Tracked problem to line 124 of includes/ckeditor.utils.js:
if (run_filter && ($("#" + textarea_id).val().length > 0) && ...
textarea_id
is empty, so $("#" + textarea_id).val()
fails.
Wrapped that if
statement (including its else
) in this:
if ( $("#" + textarea_id).size() > 0 ) {
Everything works now. No obvious evil side effects.
Comments
Comment #1
mkesicki CreditAttribution: mkesicki commentedThank you @mathieso for noticing this and for your solution. We try check and fix this as soon as possible.
Comment #2
dczepierga CreditAttribution: dczepierga commentedI commit a little fix to GIT (diff).
Pls check last DEV version. If i doesn't help pls reopen this issue.
Greetings
Comment #3
dczepierga CreditAttribution: dczepierga commentedComment #4.0
(not verified) CreditAttribution: commentedAdded a useless note about the length of this issue title.