Add support for CKEditor v4 with new option in admin panel to enable/disable "DIV-based" editor, instead of old iframe editor (DIV-based editor is enabled now by default - if CKEditor v4 is detected).

Comments

dczepierga’s picture

Status: Active » Needs review

I commit all changes to GIT (diff).

It could be more changes to work with CKEditor v4, because is not released yet.

For all who wants to review CKEditor module with new CKEditor v4 - u can download nightly build of CKE v4 library from here: http://nightly.ckeditor.com/

I will be grateful for any help.

Greetings

mkesicki’s picture

New CKEditor 4 was released yesterday . More info about it: http://ckeditor.com/blog/CKEditor-4-Launched-Inline-Editing-New-Skin-and-More

amstel’s picture

I managed to get CKEditor v4 working on a Drupal 6 installation with the 6.x-1.x-dev module version. The only drawback is that the editor doesn't appear when editing comments.

dczepierga’s picture

@amstel, but editing comments works before with CKEditor 3?

dczepierga’s picture

I change conditions order for detecting CKEditor version - now it possible to use CKEditor v4 from GIT with CKEditor module.

Changes commited to GIT (diff).

Greetings

---------------------------------------
EDIT:
Fix CKEditor v4 on popup window - changes commited to GIT (diff)

dczepierga’s picture

I change choosing skin and uicolor - now it works in iframe - it was needed for CKEditor v4 because it not possible to change skin or use few editors with diffrent skins on one page. Of course it works also with CKEditor v3.
New feature - checking skin availibility on CKEditor configuration page.
I've add this because CKEditor v4 doesn't has "kama" skin in default package (it is available in CKEditor builder or addons), so now if user has selected skin which not exists (skin files not found) warning will be displayed in CKEditor configuration page.

All changes ported from D7 and commited to GIT (diff)

------------------------------------------
EDIT:
I add next fix: set skin of profile if saved not exists, then select default one (moono or kama) or select first on the list

Changes commited to GIT (diff)

dczepierga’s picture

Fix CKEditor version detect for configuration options in admin panel.
Changes commited to GIT (diff).

dczepierga’s picture

commit fix for MediaEmbed plugin (diff).

Greetings

------------------------------
EDIT:
Add check if divarea plugin exists. If not configuration option in CKEditor profile is not visible.
Changes commited to GIT (diff).

thermador’s picture

@amstel (#3)

I was able to fix this by adding
<script type="text/javascript" src="/sites/all/libraries/ckeditor/ckeditor.js?C"></script>
to my html head in my theme page template.

The problem with using CKeditor 4, is that if you look at your HTML when the CKeditor isn't showing up at all, is that the code has an extra /. in there - it looks like this:
<script type="text/javascript" src="/./sites/all/libraries/ckeditor/ckeditor.js?C"></script>

So that's a bug right there.

I didn't know that CKeditor 4 wasn't supported lol, but using the latest CKeditor dev module for 6.x and that fix in my theme's file, and it ... mostly works. So far. Think I am going to switch to an older version though, lol..

mkesicki’s picture

Status: Needs review » Closed (fixed)