September 13

0 comments

CKEDITOR and JQUERY mismatch between versions

By NickLitten

September 13, 2012

drupal, ERPAL

This week I have been mainly using ERPAL.

If you have no point of reference with ‘The Fast Show’ then just ignore this and read on…

So, I’ve been playing with Drupal and the wonderful ERPAL Project Management module this week – I found an annoying problem where I thought I was caught between a rock and hard place. It seems that CKEDITOR 4.x needs JQuery 1.5 to work properly. But JQuery 1.5 gives me problems with some older browsers that my client is using (IE7/8) so I switch to JQUERY1.8 and the site looks good in IE but suddenly CKEDITOR it not working. Aaaargh…

Luckily, by an act of extremely good timing, the latest DEV version of JQUERY UPDATE adds the ability to switch between JQUERY versions when in normal and administration modes. So, by downloading and installing the dev version from 2013-May-02 (http://ftp.drupal.org/files/projects/jquery_update-7.x-2.x-dev.tar.gz) this lets me specify a version for the main site and a older version when in ADMIN mode.

Once you installed the Update goto http://your-site.com/admin/config/development/jquery_update

Jquery update

And set the default jQuery Version to 1.8 and the Alternate jQuery version for administrative pages to 1.5

Then we can set our theme to always use administration mode (and therefore jQuery 1.5) when editing and using CKEDITOR by going to http://your-site.com/admin/appearance and check ‘Use the administration theme when editing or creating content

Use jquery in theme

Now I view site using JQUERY 1.8 and it works great and edit using 1.5 and CKEDITOR is happy.

/groovy

{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}

Join the IBM i Community for FREE Presentations, Lessons, Hints and Tips

>