Using different versions of jQuery on the same page

Posted by nimcap on Stack Overflow See other posts from Stack Overflow or by nimcap
Published on 2010-06-17T12:36:38Z Indexed on 2010/06/17 12:43 UTC
Read the original article Hit count: 244

Filed under:
|

Users of my service includes a JS in their pages that I provide. I am hosting the script they are including. My script does some manipulation on their content. I am sick of writing my own DOM manipulators/selectors and wasting hours for jobs that can be done with 1 line of code if I can use jQuery.

Some of the users of my service already uses jQuery (or Prototype etc.) on their pages, so if I include jQuery there will be a conflict. Because there will be version differences, I don't want to use their jQuery selectors, methods either in case jQuery exists.

Keeping in mind that I have no control over their pages, how can I include jQuery and avoid conflict?

© Stack Overflow or respective owner

Related posts about jQuery

Related posts about jquery-selectors