Opened 11 years ago

Closed 11 years ago

Last modified 11 years ago

#11003 closed Bug (duplicate)

CKEditor inline editor on elements within an iframe

Reported by: George Owned by:
Priority: Normal Milestone:
Component: General Version:
Keywords: Cc:

Description

Ckeditor inline is broken when you try add it to an element with an iframe. Here are the issues associated:

  • When I scroll the iframe the toolbars do not scroll with it.
  • It does not take into account the iframe offset in the parent window

Change History (5)

comment:1 Changed 11 years ago by Piotrek Koszuliński

Resolution: duplicate
Status: newclosed

This is a duplicate of #9391.

I'm sorry for previous comment - I confused two SO questions.

comment:2 Changed 11 years ago by Piotrek Koszuliński

Version: 4.2.3 (GitHub - master)

comment:3 Changed 11 years ago by George

I think you were correct with your first comment. I was attempting to initialize CKEditor on an element inside an iframe, having CKEditor script in the outer page. I used to load CKEditor every time I load a new iframe but that causes larger loads and if this is done multiple times can have memory implications. Thanks for letting me know it won't be supported. Is there a way to set the jQuery version to use before I load it. Something like:

CKEDITOR.jQuery = window.parent.$;

comment:4 Changed 11 years ago by Piotrek Koszuliński

Actually... I started thinking on this and maybe I was wrong that such setup is not supported. It is unusual, but it does not differ a lot from a situation in which CKEditor is using iframe itself for framed editor. So code is generally ready. All code, except the floatingspace, which is not supposed to be ran in iframe, but that was already reported in #9391.

Regarding jQuery - CKEditor is using window.jQuery and we haven't provided an option to override this. However, you can fork CKEditor repo and change this here: https://github.com/ckeditor/ckeditor-dev/blob/master/adapters/jquery.js#L375

comment:5 Changed 11 years ago by George

I have taken a look at floatingspace and it references the CKEDITOR.document.getWindow() so I'll see if changing that to the current editors window fixes it

Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy