0

I want to update a really old project which is using jquery.fancybox-1.3.4.

I updated jQuery from 1.4.3 to 3.4.1 and now fancybox does not work anymore.

I downloaded the latest fancybox, but it is not working with my code...

So is there a way to run specific code in "compatibility mode" so that it runs with the old jquery version while the rest runs with the new one?

Black
  • 18,150
  • 39
  • 158
  • 271
  • 4
    Yes, but it involves a lot of hacking around and makes the code very brittle. Research [`$.noConflict()`](https://stackoverflow.com/a/1566644/519413). That being said, if this is an ongoing system your time would be far better spent removing the reliance on the out of date library so you can use the latest version of jQuery only – Rory McCrossan Nov 18 '19 at 15:40
  • 3
    The `$.noConflict` page has an example that does just this: https://api.jquery.com/jQuery.noConflict/ getting it to work your plugin is another matter... – freedomn-m Nov 18 '19 at 15:41

0 Answers0