开发者

Android CORS requests work only once?

开发者 https://www.devze.com 2023-03-07 11:43 出处:网络
When testing CORS requests under the Android emulator, I stumbled upon a strange error. Try for example following website: http://arunranga.com/examples/access-control/

When testing CORS requests under the Android emulator, I stumbled upon a strange error. Try for example following website: http://arunranga.com/examples/access-control/

When using a CORS request for the first time, everything seems to work f开发者_开发百科ine. But the second time it doesn't work anymore!

I tried following alternatives:

  • Android 2.1, 2.2, 3.0 emulators => fail
  • Android device (Samsung Apollo 5801) => fail
  • Other CORS sites (including home made CORS supported site) => fail

After restarting the browser, it works again... but again, only the first time.

I guess the problem is somewhere in the Android Webkit code. I have some experience programming Android but can not seem to find this exact problem.

Anyone met this problem and found a solution?


I ran into this just now. The Android browser has some strange caching issues you need to be aware of, so try the workarounds in [link removed][1].

0

精彩评论

暂无评论...
验证码 换一张
取 消