#8530 closed Bug (invalid)
jQuery adapter breaks save button
Reported by: | Tim | Owned by: | Garry Yao |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | General | Version: | 3.1 |
Keywords: | Cc: |
Description
When using the jQuery adapter's .ckeditor() function, the save buttons of editors created in that way are broken. The button seems to work correctly, but the text that is submitted is whatever text was in the textarea before it was replaced by an editor.
A workaround is to do
CKEDITOR.replace($(element).attr('id'), opts)
but that kindof defeats the whole purpose of the jQuery adapter.
Attachments (1)
Change History (7)
comment:1 Changed 13 years ago by
Keywords: | jquery removed |
---|---|
Status: | new → confirmed |
Version: | 3.6.2 → 3.1 |
Changed 13 years ago by
Attachment: | 8530.patch added |
---|
comment:2 Changed 13 years ago by
Owner: | set to Garry Yao |
---|---|
Status: | confirmed → review |
comment:3 Changed 13 years ago by
I just had a quick look at the patch and it seems to solve this particular issue.
I had hope that it will also solve #6906 but that would be to beautiful :
comment:4 Changed 12 years ago by
Status: | review → review_failed |
---|
On the review, I started with the presupposition that there must be a reason to have that autoUpdateElementJquery hack there and so we should not simply remove it.
I've reached the original ticket for that (#4210), which doesn't clearly explains the reason but gives an idea for it.
In fact, after that, I was able to confirm that after patch editor.updateElement is being called twice when submitting the form. To test it, I've just added a alert( 'UPDATE!' )
call inside that function.
We must definitely avoid that.
comment:5 Changed 11 years ago by
Resolution: | → invalid |
---|---|
Status: | review_failed → closed |
comment:6 Changed 11 years ago by
This bug has been fixed during general jQuery adapter bug fixing #10281.
I'm kind of surprised that no one has reported this issue earlier.
Seems that toolbar Save button doesn't send updated contents (can be checked with Firebug in Net tab) to the editor but only the default text.
Just to compare, submit placed button under the editor works as expected.
Issue has been reproducible from CKEditor 3.1 (when jQuery adapter was introduced).