Notes on jQuery 1.0 Compatibility Plugin && Interface Elements

Events happening in the community are now at Drupal community events on www.drupal.org.
joshk's picture

As I noted before, after some sleuthing, I discovered that there is a compatibility plugin (click here for source) which is designed to allow code written for jQuery 1.0 to run under jQuery 1.1. Mainly what it does is re-implement a number of deprecated functions. I'm interested in it because I would like to use several elements from the Interface Elements library.

So far so good! I've replaced the stock jquery.js with version 1.1.1, and I am including the compatibility script afterwards. Interface Elements perform fine, and I have only found (so far) one bug with Drupal core's javascripts.

The one issue I've found is in collapsible fieldsets. This patch fixes the problem, and is also compatible with jQuery 1.0, so I have no worries there.

I will continue to post from my experience, but I encourage others to use this code and see what shakes out.

Comments

Backwards compatibility

KentBye's picture

Thanks for checking into this.
I see now where the compatibility plugin fits in.

But does this mean that jQuery 1.1 is actually not backwards compatible with 1.0 despite what you said here?

Whatever the case, the good news seems to be that everything is backwards compatible with this plugin.

Well

joshk's picture

It turns out that I have to eat some crow for pushing back on the "not compatible" talk. It's right there from the man himself.

However, scripts that are well-written for 1.1 will still work in 1.0. Most scripts that rely on deprecated 1.0 methods (e.g. oneclick()) can still function under jQuery 1.1 with the compatibility plugin.

The collapse.js needs a minor patch because used an outdated way of calling the complete function. This isn't addressed in the compatibility plugin.

http://www.chapterthreellc.com | http://www.outlandishjosh.com

Hey boys, Interface make the

elio's picture

Hey boys,

Interface make the colapse.js on forms not working!!!!!!

Help !!!!
please post if you solved the problem! I tryed to include first interface but is the same!!

Javascript

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds:

Hot content this week