Problem with cache in actionscript URLLoader

In one of my flash projects, I get XML data from an aspx file. But it always shows the same data, and new data does not arrive in the request. I suspect the problem is in the cache. Below is my code

var urlloader:URLLoader=new URLLoader();
var header:URLRequestHeader = new URLRequestHeader("Cache-Control", "no-cache");
var urlRequest:URLRequest=new URLRequest(serverPath +
                                         'GetScoreDetails.aspx?CardNo='+CardNo);
fscommand("LOG", serverPath + 'GetScoreDetails.aspx?CardNo=' + CardNo );
urlRequest.requestHeaders.push(header);
urlloader.addEventListener(Event.COMPLETE, loadedCompleteHandler);
urlloader.load(urlRequest);
+5
source share
1 answer
var xmlPath:String="replaceYourXMLPathHere.xml"
var urlReq:URLRequest = new URLRequest(xmlPath+"?time=" + new Date().getTime());

http://www.newtonflash.com/blog/2009/06/08/prevent-xml-caching-problem/#comment-43

+9
source

All Articles