JQuery not firing

I have a jquery function that I have working just fine on an html page on my server. When I move everything over to a Percussion page, nothing works. Can anyone help me?

I’m calling the jquery fucntion in my page’s addtional head code and then I have an HTML widget that have a where the data is appended to.

Hey Matt,

Are you including an external jQuery library as part of this? If so, note that CM1 includes its own jQuery library by default, so including external jQuery libraries in addition can cause conflicts. Also, if this code functions outside of CM1, take note of what jQuery library you are using – CM1 ships with version 1.7.2 currently, so if your code uses functions specific to another version, it may not work in CM1. Lastly, when previewing the page which contains this code, using the Console tab in Firebug can be very useful in rooting out JavaScript errors.

In my original HTML page i did but I just included the actual jquery code in percussion.

Hey Matt, sorry, somehow I didn’t see your response. Have you double-checked what version of jQuery you were including in your original page? If it was not 1.7.2, a quick test would be to run your original code against a 1.7.2 library. Also, if you have any additional JS or jQuery code on your CM1 page that was not present on your original HTML page, you might try commenting it all out to see if any of that is causing conflicts (although this type of error should have shown up when you refreshed your page with the Firebug Console open).

Well I ended up taking the $(document).ready(function(){}); out and moved the script to the load at end of body and it works now.

Great, thanks for the update, Matt.

Incidentally, Matt, could you supply an example of the script you moved?