How to disable http caching in applet

后端 未结 2 1207
甜味超标
甜味超标 2021-01-15 11:59

How can i disable http caching of all my http connections in my japplet? I dont want any of my http (request/response)to be cached.Regardless of the user se

2条回答
  •  日久生厌
    2021-01-15 12:21

    An easy way to break caching is to add a random value to the url ala:

    String url = "http://www.example.com/?noCache=" + Math.Random();

提交回复
热议问题