jquery - jqGrid data stored in browser cache? -


does jqgrid store grid data on file system? if so, need clear browser's cache remove it?

or stored in memory javascript (and browser)? closing browser remove data?

do answers these questions change depending on whether using loadonce?

per default data loaded server (json or xml data) will saved in browser cache, not used @ next request. reason per default jqgrid implement same behavior of ajax requests cache:false parameter of jquery.ajax. means requests has additional parameter nd nd=1286296925096 timestamp. makes url of requests unique , local saved data not used twice. if want jqgrid not use data local browser cache need nothing.

if want additionally deny saving data locally (for example because of security reason or reduce filling of local cache information never used) can include no-store directive in http header of server response.

if want cache server requests , use data should prmnames: { nd:null} jqgrid option. data next requests local browser cache. if i'll recommend include in http header of server response cache-control directives force use caching behavior need. example use cache-control: max-age=0 , use etag hash data sent. ajax requests will sent server revalidate local cache. requests automatically contain if-none-match http header etag of data local cache. if data not changed server can answer response http/1.1 304 not modified having no body instead of http/1.1 200 ok body having data. response http/1.1 304 not modified allows browser use local cache.

updated: use additionally cache-control: private switch off caching data on proxy , declare data cached, not shared users.

if want read more caching control respect of http headers i'll recommend read following caching tutorial.


Comments

Popular posts from this blog

ASP.NET/SQL find the element ID and update database -

jquery - appear modal windows bottom -

c++ - Compiling static TagLib 1.6.3 libraries for Windows -