2012-03-29 12 views
0

私のWeb AppでFlexigridを使用しています。ユーザーがレコードを追加または削除すると、$( "#displays")flexReload関数が呼び出されますが、IEでは機能しません。 IEを再起動するかブラウザのキャッシュを手動でクリアする必要があります。 ありがとうございます。IEのflexReload問題

答えて

1

コーディングハッピー

**Server side solution:** Set the HTTP headers of the response to avoid returning response from cache. 

In HTML: (in the header) 

<META HTTP-EQUIV=”Cache-Control” CONTENT=”no-cache”> 
<META HTTP-EQUIV=”expires” CONTENT=”0″> 

In PHP: (in the script) 

header(”Cache-Control: no-cache, must-revalidate”); 
header(”Expires: Mon, 26 Jul 1997 05:00:00 GMT”); 

In JSP: (before writing to the output stream) 

response.setHeader(“Cache-Control”,”no-cache”); 
response.setDateHeader (“Expires”, 0); 

**Client side solution:** (1) Make HTTP POST call — only HTTP GET calls are served from cache or (2) Make sure the HTTP GET URL is different every time. 

(1) Make HTTP POST call – 
set method=”POST” and handle the call appropriately 

(2) Append a unique parameter to the HTTP GET call so that the URL is different every time. A unique time stamp is a good choice. 
The following sample code, may do the job: 

var timeStampForNocache:Date = new Date() ; 
params.noCacheControlVar = timeStampForNocache.getTime().toString() ; 
I have named the parameter “noCacheControlVar”. You can name it anything else you please. The name does not matter. What matters is that the timestamp makes the HTTP GET URL unique. 

この問題を解決するには2つの方法があります!