I'm trying to integrate jQuery and the Cycle plugin with an existing application. However, I'm running into a problem regarding load order of the javascript code. Specifically, the cycle javascript is loading before the jquery library.
I have three scripts defined on the page in the order of
<g:javascript library="jquery" />
<jq:plugin name="cycle" />
<g:javascript src="scripts.js" />
However, according to Firebug's NET tab, the cycle plugin is loading first, then the script javascript code, and followed by the jquery library. The end result is the first image of the slideshow is being displayed, but the transistion is not happening.
How do I change the load order?
The solution was to manually download the jquery file and save it in the /web-app/js, then
including <script type="text/javascript" src="${resource(dir:'js', file:'jquery-1.7.2.js') }"></script>
in the head tag. Previously, relying on the installed plugin resulted in delayed loading of the jQuery library and thus my problem.