How can I ensure that "lightbox" JavaScriptReference (see below) is
loaded after the two HeaderContributions (prototype and scriptaculous)?
- Headercontributions:
add(JavascriptPackageResource.getHeaderContribution(this.getClass(),
"js/prototype.js"));
add(JavascriptPackageResource.getHeaderContribution(this.getClass(),
"js/scriptaculous.js?load=effects,builder"));
- JavaScriptReference:
add(new JavaScriptReference("lightbox", new
TextTemplateResourceReference(this.getClass(), "js/lightbox.js",
"text/javascript", new LoadableDetachableModel<Map<String, Object>>()
{...}})));
and in HTML of this Panel:
<wicket:head>
<script wicket:id="lightbox" src="#" language="JavaScript"></script>
</wicket:head>
The result is always this order in the HTML:
<script wicket:id="lightbox"
src="resources/LightBox2Panel/js/lightbox.js" language="JavaScript"
type="text/javascript"></script>
<script type="text/javascript"
src="resources/LightBox2Panel/js/prototype.js"></script>
<script type="text/javascript"
src="resources/LightBox2Panel/js/scriptaculous.js?load=effects,builder"></script>
I already tried to load the HeaderContributions as JavaScriptReference, too, and
defining the order in the Panel-HTML-template, but then I can not pass the
URL-params to scriptaculous.js...
Any ideas?
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]