Log in or register to post comments
Last post
cherouvim's picture
Joined: 06/10/2010
Posts: 3
adding CKEditor 3.x in an iframe like in 2.x
Hello

I've got a webpage css (with some !important rules) which overrides and completely desctroys the CKEditor 3 style.
That happens because CKEditor now embeds the buttons in div/tables inside the host page and only the rich textarea in an iframe. The old FCKeditor didn't have this problem because all of it was embeded in an iframe.

Is there a solution for this?

thanks
alfonsoml's picture
Joined: 31/12/2006
Posts: 3749
Re: adding CKEditor 3.x in an iframe like in 2.x
You can create your own wrapper and put each CKEditor instance in an iframe.
cherouvim's picture
Joined: 06/10/2010
Posts: 3
Re: adding CKEditor 3.x in an iframe like in 2.x
alfonsoml wrote:You can create your own wrapper and put each CKEditor instance in an iframe.

Correct, but won't I also need to replicate the edited content from the iframe back to the original textarea so the updated data is sent when submitting the form?
alfonsoml's picture
Joined: 31/12/2006
Posts: 3749
Re: adding CKEditor 3.x in an iframe like in 2.x
Yes, you'll need some code to talk between the iframe and the main document.
I didn't say that this would be an easy task, maybe there's some shortcut and it isn't hard, but I've never saw anyone with this requirement.
cherouvim's picture
Joined: 06/10/2010
Posts: 3
Re: adding CKEditor 3.x in an iframe like in 2.x
Imagine that I need to inject CKEditor instances directly inside other people's websites. Their master CSS (which I do not easily control and may contain many !important rules) may heavily affect the way CKEditor looks (to the point where it's not usable).
Previously (2.x) this wasn't a problem by default.

Was the root iframe removed in 3.x for performance reasons?
alfonsoml's picture
Joined: 31/12/2006
Posts: 3749
Re: adding CKEditor 3.x in an iframe like in 2.x
cherouvim wrote:
Was the root iframe removed in 3.x for performance reasons?


Yes
henksalomons's picture
Joined: 13/02/2012
Posts: 2
Re: adding CKEditor 3.x in an iframe like in 2.x
Have you found a sollution, or a walkthrough for this, i have a similar problem.

e.g. i'm working on migrating the fckeditor 2.x to ckeditor 3.x in an in house build CMS witch works with dialogs on iframes bases. In the iframe i have an editor instance. The problem is when i open an ckeditor dialog the parent iframe limits its size.

Any help?