Using JQuery and Prototype in the same page

前端 未结 12 1229
忘了有多久
忘了有多久 2020-11-30 03:39

Several of my pages use both JQuery and Protoype. Since I upgraded to version 1.3 of JQuery this appears to be causing problems, because both libraries define a function nam

12条回答
  •  被撕碎了的回忆
    2020-11-30 04:33

    You need to load it in your public/javascript/application.js

    jQuery.noConflict();
    
    var $j = jQuery;
    

    This is also a good article that may be helpful.

    JQuery & Prototype working together

提交回复
热议问题