Sep 29, 2010, 5:54 PM
-
-
Sep 29, 2010, 5:58 PMNo Prob Geoff... The issue can be marked solved as soon as you add a property somewhere for disablePostCache. Or rather update the code to not cache both post and get.
Trying to override Ext.data.Connection.request.
Its been really long we are trying to find a solution for this and finally it looks near :) -
Sep 29, 2010, 7:46 PMHi,
Please update from SVN. Now POST ajax requests (DirectEvent/DirectMethod) with cache buster by default under Chrome Frame
Also we added DisableCaching and DisableCachingParam properties for overriding for particular direct event/method. On the global level you can do it via javascript
Ext.net.DirectEvent.disableCaching Ext.net.DirectEvent.disableCachingParam
-
Sep 29, 2010, 7:55 PMHi Vlad,
I would like to get to your notice that, its important this setting remains same for all browsers.
Reason being, in my tests, on pageload, GET request is cached, however, on subsequent post request, the cache is invalidated and then if you again request the page, its not loaded from cache but from the server.
In tht case, caching will work only in Chrome Frame and not in other browsers. I request you to make this default in other browsers.
I am still using an older version of Ext.Net, and at this stage cannot update from SVN. I am looking at overriding the Ext.net.DirectEvent.request method, but having some issue. -
Sep 29, 2010, 8:04 PMCan you plz check the attached file and tell me if its correct?
I have tested, and its working perfectly. Just wanted ensure I have not missed anything.
Thanks, -
Sep 29, 2010, 8:06 PMHi,
Ok, now POST ajax requests with cache buster by default for all browsers.
You can use following code to accomplish that
Ext.net.DirectEvent.on("beforerequest", function(conn, o){ var method = o.method || this.method || ((o.params || o.xmlData || o.jsonData || o.form) ? "POST" : "GET"), url = o.url || this.url, form = Ext.getDom(o.form); if(form){ url = url || form.action; } if(method === "POST" && (this.disableCaching && o.disableCaching !== false)){ if (Ext.isFunction(url)) { url = url.call(o.scope || "window", o); } var dcp = o.disableCachingParam || this.disableCachingParam; o.url = Ext.urlAppend(url, dcp + '=' + (new Date().getTime())); } }, Ext.net.DirectEvent);
-
Sep 29, 2010, 9:11 PMYou can ignore my last post....
All's well here!
Thank you so much! -
Feb 26, 2013, 6:23 AM
I Found this. Sorta Related.
http://www.superstarcoders.com/blogs...post-back.aspx
Which turns off caching on all non-GET operations, so POST will not be fed from the cache ever. -
Mar 01, 2013, 5:03 AMHi michaeld,
Thanks for your reply, but this issue was sorted long back. Almost 2.5 yrs back :)
Similar Threads
-
RowDblClick Direct Event Issue
By sumesh in forum 1.x HelpReplies: 5Last Post: May 01, 2012, 11:15 AM -
Direct method and direct event over SSL?
By dimitar in forum 1.x HelpReplies: 0Last Post: Oct 08, 2011, 8:09 PM -
[CLOSED] Multiple controls cache issue with user control on direct event...
By Suntico in forum 1.x Legacy Premium HelpReplies: 7Last Post: Jun 28, 2011, 11:13 AM -
[CLOSED] Calling a UserControl Direct Event method from a different page
By ogokgol in forum 1.x Legacy Premium HelpReplies: 1Last Post: Mar 11, 2011, 2:54 PM -
[CLOSED] [1.0] How to access a direct method event inside a user control
By Hari_CSC in forum 1.x Legacy Premium HelpReplies: 8Last Post: Jun 24, 2010, 9:39 PM