Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FIX] Allow for the iframe having been removed already #200

Conversation

StefanRijnhart
Copy link

When integrating ckeditor in Odoo, we encounter TypeError: iframe is null in http://localhost:9069/web_ckeditor4/static/lib/ckeditor/plugins/wysiwygarea/plugin.js:520 when the editor is created in a ajax popup. The editor is destroyed when the popup is closed, but by then the Odoo framework has already cleared out the DOM.

Same as #56, but I thought I'd try again.

@Reinmar
Copy link
Member

Reinmar commented Jul 31, 2015

I'm still a bit against just hiding an evidence of an issue rather than fixing the code (e.g. Odoo which should destroy CKEditor prior to destroying the DOM), but ok... let's see.

I would normally ask you for tests and some other improvements, but I want to have this researched on our side. My main doubt is whether new instances of the editor can be initialised after one of them is so ugly destroyed. Also, I want console logs notifying the developer that they destroyed CKEditor incorrectly, so this issue stays somehow visible.

We'll try to ship this in 4.5.3.

@StefanRijnhart
Copy link
Author

Thanks @Reinmar for your response. On our side, we see no problems initializing new instances of the editor on the same page after destroying old ones with this patch.

@szymonkups
Copy link
Contributor

Thanks for the PR. I've created separate ticket on Trac.
I've pushed new branch t/13790, it includes changes made in pull request plus additional test. It will be merged into master branch after the release of CKEditor 4.5.4 (which is currently in progress). I will close this PR after merge to the master branch.

@szymonkups
Copy link
Contributor

Merged into master branch with ca91770.

@hongquanvn1998
Copy link

How to call ckeditor 4.x widget for field text in odoo ? thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants