Keyword

k2 jQuery.noConfilct issue

  • Pastey
  • Pastey's Avatar Topic Author
  • Offline
  • New Member
More
12 years 4 months ago #66330 by Pastey
k2 jQuery.noConfilct issue was created by Pastey
hey,

I'm trying to reduce the number of http requests in my custom template. Ive pulled out the k2.js and loaded it into one scripts.js.php which basically just requires all the scripts i need. Pretty standard.

When when i access the front end content input form im getting this error:

jQuery is not defined

Which is issued by this line in k2.js:

var $K2 = jQuery.noConflict();

Which can be hacked (really dont want to do this) to work like this

var $K2 = jQuery

Now i can see that there will be mootools based issues later down the line. Is there any way of stopping the k2.js located in:

media/k2/assets/js

from being loaded at any point? As i load the k2.js in my parser and it works fine.

OR can i pass jQuery.noConfilct later? I thought this may work:

function($K2){

}(jQuery.noConflict())

Which doesnt work :(

Any thoughts?

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum