TurnKey Linux Virtual Appliance Library

Upgrading FCKeditor to CKeditor

I just finished upgrading the WYSIWYG editor on the web site from FCKEditor to CKEditor, which is FCKEditor's less offensively named successor.

Improvements

  • A noticeably faster, more lightweight code-base which was rewritten from the ground up.

  • Full-screen mode works beautifully now. I love how this instantly removes all the clutter and lets me focus on the content I'm editing without being distracted by the rest of the web site.

  • The edit area can be resized dynamically by dragging the window corner, giving you as much room to edit as you need. If you've ever felt uncomfortably cramped inside a tiny edit box you know what a relief it can be to escape.

  • Source mode now pretty prints your XHTML tags, with proper indenting. When you need to edit raw source, this feature makes it much easier to visually parse what you're looking at.

  • A status field provides information showing your current position in the document's tag hierarchy.

  • Advanced theming support. The new default theme Kama let's you pick a colorset to match the theme of your web site:

Personally I like Kama better but if you're feeling attached to FCKeditor's somewhat clunky looks you can select CKEditor's V2 theme which looks just like it:

Out of the box CKEditor also comes with a rather pretty Office 2003 theme:

Drupal installation and upgrade notes

On Drupal, you install CKEditor the same way you install FCKEditor. First you download CKEditor and the CKEditor Drupal module. Next, extract the CKEditor Drupal module in your site modules directory and then extract CKEditor itself into the module's directory, like this:

cd /etc/drupal/6/sites/all/modules
tar -zxvf ckeditor-6*.tar.gz
mv ckeditor_3* ckeditor
cd ckeditor
tar -zxvf ckeditor_3*

Enable the CKEditor module while disabling FCKEditor (I.e., enabling both will result in Javascript errors). Drupal's CKEditor module inherits the settings from the FCKEditor module so the upgrade is relatively painless.

If you've customized FCKEditor's button layout by editing modules/fckeditor/fckeditor.config.js you'll want to customize CKEditor's button layout as well by editing the profiles in modules/ckeditor/ckeditor.config.js. Most of the button names are the same except for a handful which have been renamed:

  • FormatName => Format
  • FontFormat => Font
  • UnorderedList => BulletedList
  • OrderedList => NumberedList
  • StrikeThrough => Strike
  • Rule => HorizontalRule

Gotcha: pop-up mode is broken (but good riddance!)

FCKEditor was slow enough that we decided to disable it by default for administrator accounts on this web site while still allowing us to launch it on demand in a pop-up when we really needed it.

The bad news is that pop-up mode doesn't work well in the version of CKEditor I've been testing so I've had to disable it. The good news is that CKEditor is fast enough now that I can enable it by default and the full-screen mode works even better for minimizing distractions.

Come to think of it, pop-up mode in FCKEditor was kind of a disaster. If you accidentally tried opening more than one editing pop-up, you would loose loose your previous edit without warning. After that happened a few times I developed a deep mistrust for FCKeditor and would edit the bulk of my content without it. Good riddance to that!

You can get future posts delivered by email or good old-fashioned RSS.
TurnKey also has a presence on Google+, Twitter and Facebook.

Comments

Drupal installation and upgrade notes

I'd just like to say a sincere, "THANK YOU"!!!  I was sent the link to this site by the author of the CKeditor SWF module (kind gentleman for sure) and your directions were excellent.  I'm not very knowledgeable in Drupal, and have had difficulty with many modules, but your instructions made it a simple task. Drupal Community needs more people like you (and CKeditor's Author).

THANK YOU!

Lee

Liraz Siri's picture

You're welcome!

Your very welcome. I wasn't sure anyone found this post useful. Thanks for proving me wrong.

Cheers

Great information!

Nice one! Im a drupal newbie and found your post very helpful!

Post new comment

The content of this field is kept private and will not be shown publicly. If you have a Gravatar account, used to display your avatar.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <p> <span> <div> <h1> <h2> <h3> <h4> <h5> <h6> <img> <map> <area> <hr> <br> <br /> <ul> <ol> <li> <dl> <dt> <dd> <table> <tr> <td> <em> <b> <u> <i> <strong> <font> <del> <ins> <sub> <sup> <quote> <blockquote> <pre> <address> <code> <cite> <strike> <caption>

More information about formatting options

Leave this field empty. It's part of a security mechanism.
(Dear spammers: moderators are notified of all new posts. Spam is deleted immediately)