KAYAK2U

January 14, 2013

CKEditor 4.0 with After the Deadline CKEditor spell/grammar plugin

What better way to spend a relentlessly rainy day than banging head against PHP and Javascript.

So, the CKEditor doesn't want to use its built in Spell Check 'gorythms in the Opera browser.  After rummaging around, I found the After the Deadline for CKEditor plugin, with its README file.

To start, extract the AtD files to the ckeditor/plugins directory.  Then copy the contents of atd.css and append them to ckeditor-for-wordpress/ckeditor/contents.css.  That's the easy parts.

Then ckeditor-for-wordpress/ckeditor.config.js needs to be tweaked.

The AtD readme says to add… 

config.extraPlugins = 'atd-ckeditor';

… but while that alone might have worked in previous versions of CKEditor, more is needed, now.  Also add… 

CKEDITOR.plugins.addExternal('atd-ckeditor', ckeditorSettings.pluginPath + 'plugins/atd-ckeditor/');

Then, in the toolbar section of the same file, add [‘atd-ckeditor’] wherever you want the spell check button located.  See previous post for toolbar layout.

But THEN, it turns out there's a small bug in the AtD plugin.js file.  Down around line 182… 

var proxy_server = editor.config.atd_rpc == undefined ? path + 'proxy.php?url=/checkDocument' : editor.config.atd_rpc;

… delete "/checkDocument".  The string is appended a few lines later.

And then it WORKS in Opera.  Sort of.  The plugin flags misspellings right enough, but the suggestion/correction feature is borked, but that's Opera's fault.

All in all I like it.  Not only does AtD find misspellings, it flags questionable grammar, too.  Passive voice much?

ps.  Which makes it official:  I now spend more time preparing to blog than I actually spend blogging.

MikeSoja - January 14, 2013 -- 08:30 pm    Filed in: Programming  
« CKEditor 4.0
Neck deep in farce »
As Happy As A Clam

Kayak2U.com

msoja RSS 2.0

Other's Pages









Search

Archive

November 2026
M T W T F S S
 1
2345678
9101112131415
16171819202122
23242526272829
30  


  • Books4Sale



    Soja's GoodReads Books4Sale Cheap

  • Category Cloud


  • Tag Cloud