Hi,

The anti cache parameter is added by jQuery itself when $.ajax({cache:
false, ...}) - http://api.jquery.com/jquery.ajax/

ack-grep '_=' wicket-core/src/main/java/
wicket-core/src/main/java/org/apache/wicket/resource/jquery/jquery-1.11.1.js
8551: rts = /([?&])_=[^&]*/,
9105: cacheURL.replace( rts, "$1_=" + nonce++ ) :
9108: cacheURL + ( rquery.test( cacheURL ) ? "&" : "?" ) + "_=" + nonce++;

wicket-ajax sets cache to false to avoid cached Ajax responses:
https://github.com/apache/wicket/blob/master/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js#L671

Can you reproduce this with a plain (i.e. no third party libs) Wicket
quickstart ?
If YES then please create a ticket and attach the quickstart.
Thanks!

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov

On Thu, Oct 30, 2014 at 3:35 PM, prasad.bhandagi <[email protected]>
wrote:

> @Martin
>
> When the first page is loaded, below is the url:
>
> http://localhost:7001/ahc/prol/wicket/resource/org.apache.wicket.resource.JQueryResourceReference/jquery/jquery-1.10.1-ver-1372037384000.js
>
> When the second page is loaded in modal window, below is the url:
>
> http://localhost:7001/ahc/prol/wicket/resource/org.apache.wicket.resource.JQueryResourceReference/jquery/jquery-1.10.1-ver-1372037384000.js?_=1414675886491
>
> Wicket for some reason is appending a query parameter the second time.
> Hence
> it is loading jQuery again when the modal window is opened.
> If the url was the same, Wicket client side filters would have not loaded
> jQuery again as you said.
> Any idea on why the "_" query parameter is being appended the second time
> and if it can be avoided?
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/Wicket-jQuery-js-loaded-twice-when-modal-window-opened-tp4668156p4668168.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>

Reply via email to