[thelist] Caching Problem - ASP/iFrame

Peter Brunone (EasyListBox.com) peter at easylistbox.com
Wed Aug 25 15:31:00 CDT 2004


Hi Rob,

	You can add two more to the list:

Response.Expiresabsolute = Now() - 1
Response.AddHeader "cache-control","private"

	In addition, you could add a reload command to your onSubmit,
like

onSubmit="parent.DO.location.href='DisplayModify.asp?pid=<%=request.Quer
yStr
ing("pid") %>';parent.DO.location.reload();"

	If those don't work, then you'll probably have to add a randomly
generated querystring parameter each time the page loads.

HTH,

Peter

-----Original Message-----
From: thelist-bounces at lists.evolt.org On Behalf Of Rob Smith

Hi list,

What else do you do when the following doesn't work when working with
ASP and iFrames?

<% Response.CacheControl = "no-cache" %>
<% Response.AddHeader "Pragma", "no-cache" %> 
<% Response.Expires = -1 %>
...
<head>
<META HTTP-Equiv="Cache-Control" Content="no-cache">
<META HTTP-EQUIV="Expires" CONTENT="-1"> 
<META HTTP-Equiv="Pragma" Content="no-cache">
...

What's happening is I've got iFrame #1 that has a basic form: <form
action="InsertModify.asp" method="get" name="InsertModify"
onSubmit="parent.DO.location.href='DisplayModify.asp?pid=<%=request.Quer
yStr
ing("pid") %>'">

As you can see, upon submitting the form, it's supposed to tell iFrame
#2 to refresh and display the results of iFrame #1's actions.

iFrame #2 has the above NO-CACHE everything above and to no avail, it
still doesn't refresh the data.

What else can I do to prevent caching? Messing with the browser settings
isn't an option.

Rob Smith




More information about the thelist mailing list