0

For example
If you have a plugin on a site that uses jQuery 1.5.x and want to create a new plugin by implementing a script which uses an older version of jQuery, for example 1.3.x or 1.4.x.

I know it probably depends on jQuery functions that are called, but if you really had to use both 1.5 and some older version of jQuery.. how would you deal with this kind of situation? Is it even possible to use 2 different versions of jQuery at the same time without drawbacks?

Thanks.

1
  • 3
    It is possible to load multiple versions of jQuery, but you will need to adapt the code that uses it to reference the correct version. If you want this to work with the WordPress wp_enqueue_script functions, you will need to register two different scripts, like jquery and jquery_13. So in theory it is doable, but in practice it will be difficult (which is why I put this in a comment and not an answer).
    – Jan Fabry
    Mar 2 '11 at 10:55
1

You could use jQuery.noConflict in your new plugin.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.