JWorld@TW the best professional Java site in Taiwan
      註冊 | 登入 | 全文檢索 | 排行榜  

» JWorld@TW » Application Server » Tomcat  

按列印兼容模式列印這個話題 列印話題    把這個話題寄給朋友 寄給朋友   
reply to topicthreaded modego to previous topicgo to next topic
本主題所含的標籤
無標籤
作者 javascript js 檔被tomcat catch?
yonc





發文: 5
積分: 0
於 2011-10-27 11:43 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
請問各位遇過 js 被catch住的問題嗎?
也就是 js 檔修改完,重新覆蓋至 server...
不管 ap server(tomcat) 怎麼重啟,還是會抓住舊的檔案,
非得重新開機,才會持行新的程式碼....


reply to postreply to post
作者 Re:javascript js 檔被tomcat catch? [Re:yonc]
ynchang





發文: 151
積分: 0
於 2011-10-27 12:59 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
請問你是用IE開啟網頁的嗎???
如果是的話,可以試看看把IE的Cache清掉
記得IE在某些狀況會Cache住Java Script


reply to postreply to post
作者 Re:javascript js 檔被tomcat catch? [Re:yonc]
yonc





發文: 5
積分: 0
於 2011-10-27 14:37 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
用google 找到了....

要在web.xml 加上 <filter-name>NoCache</filter-name><url-pattern>*.js</url-pattern> ...


reply to postreply to post
作者 Re:javascript js 檔被tomcat catch? [Re:yonc]
reggie

Java Life



發文: 238
積分: 1
於 2011-11-04 19:55 user profilesend a private message to usersend email to reggiereply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
javascript url 加上 queryString可以避免browser cache

1
<script type="text/javascript" src="scripts/test.js?timestamp=123412341234"/>


reply to postreply to post
愈來愈喜歡吃蘋果了
» JWorld@TW »  Application Server » Tomcat

reply to topicthreaded modego to previous topicgo to next topic
  已讀文章
  新的文章
  被刪除的文章
Jump to the top of page

JWorld@TW 本站商標資訊

Powered by Powerful JuteForum® Version Jute 1.5.8