|
.net
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
output cache questionThis might not be the forum for this but oh well...
I have a web app that writes fields into a PDF document, it then displays a link to this document via an anchor tag. Here is where I get confused: even though in the file system the PDF document gets overwritten each time the page is traversed (i.e. each time the page is browsed to it iterates through the session var list and writes out a new pdf) when the page is displayed and the anchor is clicked up comes the previous pdf doc in the adobe i.e. snap in even though in the file system it is now replaced? I think basically the browser is caching the doc I need to cause it to not do that any ideas. This is what I have now: <%@ OutputCache Duration="0" VaryByParam="None" Location="Any" %> you are controlling the caching of the page with the anchor, but not the
caching of the actual pdf file, which is handled by iis and the users browser settings. usually the browser is set check once a session for updates of files. at a performance and scaling cost, you can write up an asp.net page or module that sets the caching headers. a note of caution, to display a pdf file in the browser requires serveral (2 - 6 downloads depending on browser version), so you don't want no-cache. this is becuase the browser donloads the file, determine the mime type requires another application to display, loads the application, then gives the application the url, which download the file again (if cached the second download comes from the cache). -- bruce (sqlwork.com) <merri***@gmail.com> wrote in message Show quoteHide quote news:1137194408.120187.303770@g49g2000cwa.googlegroups.com... > This might not be the forum for this but oh well... > > I have a web app that writes fields into a PDF document, it then > displays a link to this document via an anchor tag. Here is where I > get confused: > even though in the file system the PDF document gets overwritten each > time the page is traversed (i.e. each time the page is browsed to it > iterates through the session var list and writes out a new pdf) when > the page is displayed and the anchor is clicked up comes the previous > pdf doc in the adobe i.e. snap in even though in the file system it is > now replaced? I think basically the browser is caching the doc I need > to cause it to not do that any ideas. > > This is what I have now: > > <%@ OutputCache Duration="0" VaryByParam="None" Location="Any" %> >
Other interesting topics
Is this static method threadsafe?
Advantages of Static Vs Instance methods? Use validationSummary to display error message in user control CompareValidator for dates > than today this should be easy... VWD 2005 Express: "copy web site" creates multiple publishform (2.0) Trap the Maximum request length session values Download multiplefiles What is better for a web page???? |
|||||||||||||||||||||||