javascript - ?ver= at the end of include - is there a technical effect? - Stack Overflow

I wonder what exactly the version nameing does?like jquery.js?ver=1.4.4I mean if I use a cdn like this

I wonder what exactly the version nameing does?

like jquery.js?ver=1.4.4

I mean if I use a cdn like this jquery/1.4.4/jquery.min.js?ver=1.4.4 but another side has jquery/1.4.4/jquery.min.js?ver=1.3.2 in there, does this effect caching?

I wonder what exactly the version nameing does?

like jquery.js?ver=1.4.4

I mean if I use a cdn like this jquery/1.4.4/jquery.min.js?ver=1.4.4 but another side has jquery/1.4.4/jquery.min.js?ver=1.3.2 in there, does this effect caching?

Share Improve this question edited Jan 12, 2019 at 15:28 Cœur 38.8k25 gold badges206 silver badges279 bronze badges asked Dec 17, 2010 at 22:27 MrGlasspooleMrGlasspoole 4452 gold badges4 silver badges15 bronze badges
Add a ment  | 

1 Answer 1

Reset to default 8

Yes, by changing the =1.4.4 to something else, it forces the file to not be cached by the browser when a user es back to the page. So if you upgraded to a new version of JQuery say 1.4.5, and you wanted to make sure that the client got the most current version of the file, you change the end of the url. This makes the browser think that it's a brand new file and forces it to download the new version.

(Having the version at the end helps you easily identify which version of the file you have, but that is totally aside from what is being asked :) ).

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745605402a4635644.html

相关推荐

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信