且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

AS3当我用装载机,我总是得到则httpStatus code 200事件虽然则httpStatus code。在谷歌浏览器304

更新时间:2023-02-16 09:00:00

使用随机数生成的新的联系,避免缓存效果

Use a random number to generate "new" links and avoid the cache effect

    var loader:URLLoader = new URLLoader();
    var noCache:Number = Math.random()
    loader.addEventListener(
        HTTPStatusEvent.HTTP_STATUS, 
        function(e:HTTPStatusEvent):void {
            trace('http status : ' + e.status)
        } 
    )
    loader.load(new URLRequest('http://www.example.com?c='+noCache));