In what situation you would use multiple version of jQuery and how would you include them?
Answer / chaitanya
Well, it is quite possible that the jQuery plugins which are used are dependent on older version but for your own jQuery code, you would like to use newer version. So because of this dependency, multiple version of jQuery may required sometimes on single page.
Below code shows how to include multiple version of jQuery.
Hide Copy Code
<script type='text/javascript' src='js/jquery_1.9.1.min.js'></script>
<script type='text/javascript'>
var $jq = jQuery.noConflict();
</script>
<script type='text/javascript' src='js/jquery_1.7.2.min.js'></script>
By this way, for your own jQuery code use "$jq", instead of "$" as "$jq" refers to jQuery 1.9.1, where "$" refers to 1.7.2.
| Is This Answer Correct ? | 0 Yes | 0 No |
Where jQuery code is getting executed?
How did you become the creator of jquery ui? Whats the story behind that?
Explain "beforesend(xhr)" paremeter of jquery ajax method?
How jQuery selectors are executed?
How to resolve conflicts with other libraries?
Whether we need to add jQuery file in both Master and Content page?
How to validate email using jquery?
What's next on the hitlist with jquery ui?
Difference between find() and closest() in jquery?
What is a cdn? : jQuery Mobile
what does $("div") will select? : jquery mobile
Is there any difference between body onload() and document.ready() function?