469,603 Members | 2,049 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,603 developers. It's quick & easy.

Question: How can I "expire" a web page (prevent BACK button)

I know some sites will display the following message if you click on the
BACK button in your browser. How do I implement this feature?

Warning: Page has Expired The page you requested was created using
information you submitted in a form. This page is no longer available. As a
security precaution, Internet Explorer does not automatically resubmit your
information for you.

To resubmit your information and view this Web page, click the Refresh
button.
Nov 17 '05 #1
12 9873
Response.SetCacheability(nocache enum) roughly

"VB Programmer" <gr*********@go-intech.com> wrote in message
news:e8**************@TK2MSFTNGP10.phx.gbl...
I know some sites will display the following message if you click on the
BACK button in your browser. How do I implement this feature?

Warning: Page has Expired The page you requested was created using
information you submitted in a form. This page is no longer available. As a security precaution, Internet Explorer does not automatically resubmit your information for you.

To resubmit your information and view this Web page, click the Refresh
button.

Nov 17 '05 #2
Thanks. In the Page_Load even I tried both:

Response.Cache.SetCacheability(HttpCacheability.Se rverAndNoCache)
and
Response.Cache.SetCacheability(HttpCacheability.No Cache )

But, I can still hit the BACK button and see the page. Ideas?

"Alvin Bruney" <vapordan_spam_me_not@hotmail_no_spamhotmail.com > wrote in
message news:Oc**************@TK2MSFTNGP12.phx.gbl...
Response.SetCacheability(nocache enum) roughly

"VB Programmer" <gr*********@go-intech.com> wrote in message
news:e8**************@TK2MSFTNGP10.phx.gbl...
I know some sites will display the following message if you click on the
BACK button in your browser. How do I implement this feature?

Warning: Page has Expired The page you requested was created using
information you submitted in a form. This page is no longer available.
As a
security precaution, Internet Explorer does not automatically resubmit

your
information for you.

To resubmit your information and view this Web page, click the Refresh
button.


Nov 17 '05 #3
could it be caching on a proxy ... in the old asp world we would do the
following:

Response.Expires = -1

Response.AddHeader "Pragma", "No-Cache"

Response.CacheControl = "no-cache"

"VB Programmer" <gr*********@go-intech.com> wrote in message
news:e9*************@TK2MSFTNGP10.phx.gbl...
Thanks. In the Page_Load even I tried both:

Response.Cache.SetCacheability(HttpCacheability.Se rverAndNoCache)
and
Response.Cache.SetCacheability(HttpCacheability.No Cache )

But, I can still hit the BACK button and see the page. Ideas?

"Alvin Bruney" <vapordan_spam_me_not@hotmail_no_spamhotmail.com > wrote in
message news:Oc**************@TK2MSFTNGP12.phx.gbl...
Response.SetCacheability(nocache enum) roughly

"VB Programmer" <gr*********@go-intech.com> wrote in message
news:e8**************@TK2MSFTNGP10.phx.gbl...
I know some sites will display the following message if you click on the BACK button in your browser. How do I implement this feature?

Warning: Page has Expired The page you requested was created using
information you submitted in a form. This page is no longer available.

As
a
security precaution, Internet Explorer does not automatically resubmit

your
information for you.

To resubmit your information and view this Web page, click the Refresh
button.



Nov 17 '05 #4
Thanks. I've tried...

Response.Expires=-1

also...

Response.Cache.SetExpires(DateTime.Now.AddSeconds( 0))
Response.Cache.SetCacheability(HttpCacheability.No Cache)

It still let's me go "BACK" to the form. Any ideas?

"Dhananjay Modak" <dh*************@newellandbudge.com> wrote in message
news:OZ**************@TK2MSFTNGP11.phx.gbl...
could it be caching on a proxy ... in the old asp world we would do the
following:

Response.Expires = -1

Response.AddHeader "Pragma", "No-Cache"

Response.CacheControl = "no-cache"

"VB Programmer" <gr*********@go-intech.com> wrote in message
news:e9*************@TK2MSFTNGP10.phx.gbl...
Thanks. In the Page_Load even I tried both:

Response.Cache.SetCacheability(HttpCacheability.Se rverAndNoCache)
and
Response.Cache.SetCacheability(HttpCacheability.No Cache )

But, I can still hit the BACK button and see the page. Ideas?

"Alvin Bruney" <vapordan_spam_me_not@hotmail_no_spamhotmail.com > wrote in message news:Oc**************@TK2MSFTNGP12.phx.gbl...
Response.SetCacheability(nocache enum) roughly

"VB Programmer" <gr*********@go-intech.com> wrote in message
news:e8**************@TK2MSFTNGP10.phx.gbl...
> I know some sites will display the following message if you click on the > BACK button in your browser. How do I implement this feature?
>
> Warning: Page has Expired The page you requested was created using
> information you submitted in a form. This page is no longer available. As
a
> security precaution, Internet Explorer does not automatically

resubmit your
> information for you.
>
> To resubmit your information and view this Web page, click the Refresh > button.
>
>



Nov 17 '05 #5
I know this does basically one way or another what you are going for, but it
should force a refresh to the server.

bill

<meta http-equiv="expires" content="Sun, Dec 31 1970 12:00:00 GMT" />
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="pragma" content="no-cache" />
"VB Programmer" <gr*********@go-intech.com> wrote in message
news:Om**************@TK2MSFTNGP12.phx.gbl...
Thanks. I've tried...

Response.Expires=-1

also...

Response.Cache.SetExpires(DateTime.Now.AddSeconds( 0))
Response.Cache.SetCacheability(HttpCacheability.No Cache)

It still let's me go "BACK" to the form. Any ideas?

"Dhananjay Modak" <dh*************@newellandbudge.com> wrote in message
news:OZ**************@TK2MSFTNGP11.phx.gbl...
could it be caching on a proxy ... in the old asp world we would do the
following:

Response.Expires = -1

Response.AddHeader "Pragma", "No-Cache"

Response.CacheControl = "no-cache"

"VB Programmer" <gr*********@go-intech.com> wrote in message
news:e9*************@TK2MSFTNGP10.phx.gbl...
Thanks. In the Page_Load even I tried both:

Response.Cache.SetCacheability(HttpCacheability.Se rverAndNoCache) and
Response.Cache.SetCacheability(HttpCacheability.No Cache )

But, I can still hit the BACK button and see the page. Ideas?

"Alvin Bruney" <vapordan_spam_me_not@hotmail_no_spamhotmail.com > wrote in message news:Oc**************@TK2MSFTNGP12.phx.gbl...
> Response.SetCacheability(nocache enum) roughly
>
> "VB Programmer" <gr*********@go-intech.com> wrote in message
> news:e8**************@TK2MSFTNGP10.phx.gbl...
> > I know some sites will display the following message if you click
on
the
> > BACK button in your browser. How do I implement this feature?
> >
> > Warning: Page has Expired The page you requested was created using
> > information you submitted in a form. This page is no longer

available. As
> a
> > security precaution, Internet Explorer does not automatically resubmit > your
> > information for you.
> >
> > To resubmit your information and view this Web page, click the Refresh > > button.
> >
> >
>
>



Nov 17 '05 #6
Thanks.

Tried that also. It didn't work. Any more ideas?

Any links to samples, etc..?

"William F. Robertson, Jr." <wf*********@kpmg.com> wrote in message
news:uF**************@tk2msftngp13.phx.gbl...
I know this does basically one way or another what you are going for, but it should force a refresh to the server.

bill

<meta http-equiv="expires" content="Sun, Dec 31 1970 12:00:00 GMT" />
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="pragma" content="no-cache" />
"VB Programmer" <gr*********@go-intech.com> wrote in message
news:Om**************@TK2MSFTNGP12.phx.gbl...
Thanks. I've tried...

Response.Expires=-1

also...

Response.Cache.SetExpires(DateTime.Now.AddSeconds( 0))
Response.Cache.SetCacheability(HttpCacheability.No Cache)

It still let's me go "BACK" to the form. Any ideas?

"Dhananjay Modak" <dh*************@newellandbudge.com> wrote in message
news:OZ**************@TK2MSFTNGP11.phx.gbl...
could it be caching on a proxy ... in the old asp world we would do the following:

Response.Expires = -1

Response.AddHeader "Pragma", "No-Cache"

Response.CacheControl = "no-cache"

"VB Programmer" <gr*********@go-intech.com> wrote in message
news:e9*************@TK2MSFTNGP10.phx.gbl...
> Thanks. In the Page_Load even I tried both:
>
> Response.Cache.SetCacheability(HttpCacheability.Se rverAndNoCache)
> and
> Response.Cache.SetCacheability(HttpCacheability.No Cache )
>
> But, I can still hit the BACK button and see the page. Ideas?
>
> "Alvin Bruney" <vapordan_spam_me_not@hotmail_no_spamhotmail.com > wrote
in
> message news:Oc**************@TK2MSFTNGP12.phx.gbl...
> > Response.SetCacheability(nocache enum) roughly
> >
> > "VB Programmer" <gr*********@go-intech.com> wrote in message
> > news:e8**************@TK2MSFTNGP10.phx.gbl...
> > > I know some sites will display the following message if you
click on the
> > > BACK button in your browser. How do I implement this feature?
> > >
> > > Warning: Page has Expired The page you requested was created

using > > > information you submitted in a form. This page is no longer

available.
> As
> > a
> > > security precaution, Internet Explorer does not automatically

resubmit
> > your
> > > information for you.
> > >
> > > To resubmit your information and view this Web page, click the

Refresh
> > > button.
> > >
> > >
> >
> >
>
>



Nov 17 '05 #7
That page about resubmitting you're talking about does not come from the
server. It is shown by IE and you will see if when you come back to a page
that got form submitted through POST method to it. If you come back to such
a page IE (or any other client for that matter) will not automatically
resubmit the form.

Jerry

"VB Programmer" <gr*********@go-intech.com> wrote in message
news:el**************@tk2msftngp13.phx.gbl...
Thanks.

Tried that also. It didn't work. Any more ideas?

Any links to samples, etc..?

"William F. Robertson, Jr." <wf*********@kpmg.com> wrote in message
news:uF**************@tk2msftngp13.phx.gbl...
I know this does basically one way or another what you are going for, but
it
should force a refresh to the server.

bill

<meta http-equiv="expires" content="Sun, Dec 31 1970 12:00:00 GMT" />
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="pragma" content="no-cache" />
"VB Programmer" <gr*********@go-intech.com> wrote in message
news:Om**************@TK2MSFTNGP12.phx.gbl...
Thanks. I've tried...

Response.Expires=-1

also...

Response.Cache.SetExpires(DateTime.Now.AddSeconds( 0))
Response.Cache.SetCacheability(HttpCacheability.No Cache)

It still let's me go "BACK" to the form. Any ideas?

"Dhananjay Modak" <dh*************@newellandbudge.com> wrote in message news:OZ**************@TK2MSFTNGP11.phx.gbl...
> could it be caching on a proxy ... in the old asp world we would do

the > following:
>
> Response.Expires = -1
>
> Response.AddHeader "Pragma", "No-Cache"
>
> Response.CacheControl = "no-cache"
>
>
>
> "VB Programmer" <gr*********@go-intech.com> wrote in message
> news:e9*************@TK2MSFTNGP10.phx.gbl...
> > Thanks. In the Page_Load even I tried both:
> >
> >
Response.Cache.SetCacheability(HttpCacheability.Se rverAndNoCache)
> > and
> > Response.Cache.SetCacheability(HttpCacheability.No Cache )
> >
> > But, I can still hit the BACK button and see the page. Ideas?
> >
> > "Alvin Bruney" <vapordan_spam_me_not@hotmail_no_spamhotmail.com > wrote in
> > message news:Oc**************@TK2MSFTNGP12.phx.gbl...
> > > Response.SetCacheability(nocache enum) roughly
> > >
> > > "VB Programmer" <gr*********@go-intech.com> wrote in message
> > > news:e8**************@TK2MSFTNGP10.phx.gbl...
> > > > I know some sites will display the following message if you click
on
> the
> > > > BACK button in your browser. How do I implement this feature?
> > > >
> > > > Warning: Page has Expired The page you requested was created

using > > > > information you submitted in a form. This page is no longer
available.
> > As
> > > a
> > > > security precaution, Internet Explorer does not automatically
resubmit
> > > your
> > > > information for you.
> > > >
> > > > To resubmit your information and view this Web page, click the
Refresh
> > > > button.
> > > >
> > > >
> > >
> > >
> >
> >
>
>



Nov 17 '05 #8
As I stated in my original message I would like my browser to give me a
"Warning: Page has Expired..." message, like it does if you try hitting the
BACK key in a secure website (PayPal.com, etc...)

Robert

"Jerry III" <je******@hotmail.com> wrote in message
news:Ot*************@TK2MSFTNGP10.phx.gbl...
That page about resubmitting you're talking about does not come from the
server. It is shown by IE and you will see if when you come back to a page
that got form submitted through POST method to it. If you come back to such a page IE (or any other client for that matter) will not automatically
resubmit the form.

Jerry

"VB Programmer" <gr*********@go-intech.com> wrote in message
news:el**************@tk2msftngp13.phx.gbl...
Thanks.

Tried that also. It didn't work. Any more ideas?

Any links to samples, etc..?

"William F. Robertson, Jr." <wf*********@kpmg.com> wrote in message
news:uF**************@tk2msftngp13.phx.gbl...
I know this does basically one way or another what you are going for, but
it
should force a refresh to the server.

bill

<meta http-equiv="expires" content="Sun, Dec 31 1970 12:00:00 GMT" />
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="pragma" content="no-cache" />
"VB Programmer" <gr*********@go-intech.com> wrote in message
news:Om**************@TK2MSFTNGP12.phx.gbl...
> Thanks. I've tried...
>
> Response.Expires=-1
>
> also...
>
> Response.Cache.SetExpires(DateTime.Now.AddSeconds( 0))
> Response.Cache.SetCacheability(HttpCacheability.No Cache)
>
> It still let's me go "BACK" to the form. Any ideas?
>
> "Dhananjay Modak" <dh*************@newellandbudge.com> wrote in message > news:OZ**************@TK2MSFTNGP11.phx.gbl...
> > could it be caching on a proxy ... in the old asp world we would d o the
> > following:
> >
> > Response.Expires = -1
> >
> > Response.AddHeader "Pragma", "No-Cache"
> >
> > Response.CacheControl = "no-cache"
> >
> >
> >
> > "VB Programmer" <gr*********@go-intech.com> wrote in message
> > news:e9*************@TK2MSFTNGP10.phx.gbl...
> > > Thanks. In the Page_Load even I tried both:
> > >
> > >
> Response.Cache.SetCacheability(HttpCacheability.Se rverAndNoCache)
> > > and
> > >

Response.Cache.SetCacheability(HttpCacheability.No Cache ) > > >
> > > But, I can still hit the BACK button and see the page. Ideas?
> > >
> > > "Alvin Bruney" <vapordan_spam_me_not@hotmail_no_spamhotmail.com >

wrote
> in
> > > message news:Oc**************@TK2MSFTNGP12.phx.gbl...
> > > > Response.SetCacheability(nocache enum) roughly
> > > >
> > > > "VB Programmer" <gr*********@go-intech.com> wrote in message
> > > > news:e8**************@TK2MSFTNGP10.phx.gbl...
> > > > > I know some sites will display the following message if you

click
on
> > the
> > > > > BACK button in your browser. How do I implement this feature? > > > > >
> > > > > Warning: Page has Expired The page you requested was created

using
> > > > > information you submitted in a form. This page is no longer
> available.
> > > As
> > > > a
> > > > > security precaution, Internet Explorer does not automatically > resubmit
> > > > your
> > > > > information for you.
> > > > >
> > > > > To resubmit your information and view this Web page, click the > Refresh
> > > > > button.
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>



Nov 17 '05 #9


From what I could tell, the expire notice when you press
back is caused by the page submitting form variables. If
you have the page submit a form (along with a couple
variables) to get to the next page, you should receive
the message when you click back.
-----Original Message-----
Thanks. I've tried...

Response.Expires=-1

also...

Response.Cache.SetExpires(DateTime.Now.AddSeconds (0)) Response.Cache.SetCacheability (HttpCacheability.NoCache)
It still let's me go "BACK" to the form. Any ideas?

"Dhananjay Modak" <dh*************@newellandbudge.com> wrote in messagenews:OZ**************@TK2MSFTNGP11.phx.gbl...
could it be caching on a proxy ... in the old asp world we would do the
following:

Response.Expires = -1

Response.AddHeader "Pragma", "No-Cache"

Response.CacheControl = "no-cache"

"VB Programmer" <gr*********@go-intech.com> wrote in message news:e9*************@TK2MSFTNGP10.phx.gbl...
> Thanks. In the Page_Load even I tried both:
>
>Response.Cache.SetCacheability (HttpCacheability.ServerAndNoCache)
> and
> Response.Cache.SetCacheability (HttpCacheability.NoCache ) >
> But, I can still hit the BACK button and see the page. Ideas? >
> "Alvin Bruney" <vapordan_spam_me_not@hotmail_no_spamhotmail.com > wrotein
> message news:Oc**************@TK2MSFTNGP12.phx.gbl...
> > Response.SetCacheability(nocache enum) roughly
> >
> > "VB Programmer" <gr*********@go-intech.com> wrote
in message > > news:e8**************@TK2MSFTNGP10.phx.gbl...
> > > I know some sites will display the following message if you click on the
> > > BACK button in your browser. How do I implement
this feature? > > >
> > > Warning: Page has Expired The page you requested was created using > > > information you submitted in a form. This page

is no longeravailable. > As
> > a
> > > security precaution, Internet Explorer does not
automatically
resubmit > > your
> > > information for you.
> > >
> > > To resubmit your information and view this Web
page, click the
Refresh > > > button.
> > >
> > >
> >
> >
>
>


.

Nov 17 '05 #10
Do you want me to repeat myself? This happens when you submit data to that
page through POST. It has absolutely NOTHING to do with page expiration.

Jerry

"VB Programmer" <gr*********@go-intech.com> wrote in message
news:Od*************@TK2MSFTNGP12.phx.gbl...
As I stated in my original message I would like my browser to give me a
"Warning: Page has Expired..." message, like it does if you try hitting the BACK key in a secure website (PayPal.com, etc...)

Robert

"Jerry III" <je******@hotmail.com> wrote in message
news:Ot*************@TK2MSFTNGP10.phx.gbl...
That page about resubmitting you're talking about does not come from the
server. It is shown by IE and you will see if when you come back to a page
that got form submitted through POST method to it. If you come back to such
a page IE (or any other client for that matter) will not automatically
resubmit the form.

Jerry

"VB Programmer" <gr*********@go-intech.com> wrote in message
news:el**************@tk2msftngp13.phx.gbl...
Thanks.

Tried that also. It didn't work. Any more ideas?

Any links to samples, etc..?

"William F. Robertson, Jr." <wf*********@kpmg.com> wrote in message
news:uF**************@tk2msftngp13.phx.gbl...
> I know this does basically one way or another what you are going for,
but
it
> should force a refresh to the server.
>
> bill
>
> <meta http-equiv="expires" content="Sun, Dec 31 1970 12:00:00 GMT"

/> > <meta http-equiv="cache-control" content="no-cache">
> <meta http-equiv="pragma" content="no-cache" />
>
>
> "VB Programmer" <gr*********@go-intech.com> wrote in message
> news:Om**************@TK2MSFTNGP12.phx.gbl...
> > Thanks. I've tried...
> >
> > Response.Expires=-1
> >
> > also...
> >
> > Response.Cache.SetExpires(DateTime.Now.AddSeconds( 0))
> > Response.Cache.SetCacheability(HttpCacheability.No Cache)
> >
> > It still let's me go "BACK" to the form. Any ideas?
> >
> > "Dhananjay Modak" <dh*************@newellandbudge.com> wrote in

message
> > news:OZ**************@TK2MSFTNGP11.phx.gbl...
> > > could it be caching on a proxy ... in the old asp world we would d o the
> > > following:
> > >
> > > Response.Expires = -1
> > >
> > > Response.AddHeader "Pragma", "No-Cache"
> > >
> > > Response.CacheControl = "no-cache"
> > >
> > >
> > >
> > > "VB Programmer" <gr*********@go-intech.com> wrote in message
> > > news:e9*************@TK2MSFTNGP10.phx.gbl...
> > > > Thanks. In the Page_Load even I tried both:
> > > >
> > > >
> > Response.Cache.SetCacheability(HttpCacheability.Se rverAndNoCache)
> > > > and
> > > > Response.Cache.SetCacheability(HttpCacheability.No Cache ) > > > >
> > > > But, I can still hit the BACK button and see the page. Ideas?
> > > >
> > > > "Alvin Bruney"
<vapordan_spam_me_not@hotmail_no_spamhotmail.com > wrote
> > in
> > > > message news:Oc**************@TK2MSFTNGP12.phx.gbl...
> > > > > Response.SetCacheability(nocache enum) roughly
> > > > >
> > > > > "VB Programmer" <gr*********@go-intech.com> wrote in message
> > > > > news:e8**************@TK2MSFTNGP10.phx.gbl...
> > > > > > I know some sites will display the following message if you click
> on
> > > the
> > > > > > BACK button in your browser. How do I implement this

feature? > > > > > >
> > > > > > Warning: Page has Expired The page you requested was created using
> > > > > > information you submitted in a form. This page is no longer > > available.
> > > > As
> > > > > a
> > > > > > security precaution, Internet Explorer does not automatically > > resubmit
> > > > > your
> > > > > > information for you.
> > > > > >
> > > > > > To resubmit your information and view this Web page, click the > > Refresh
> > > > > > button.
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>



Nov 17 '05 #11
Like other have said - you ONLY will get this when a FORM is involved on the
page.

--
Michael Tissington
Oaklodge Technologies
http://www.oaklodge.com/technology

"VB Programmer" <gr*********@go-intech.com> wrote in message
news:e8**************@TK2MSFTNGP10.phx.gbl...
I know some sites will display the following message if you click on the
BACK button in your browser. How do I implement this feature?

Warning: Page has Expired The page you requested was created using
information you submitted in a form. This page is no longer available. As a security precaution, Internet Explorer does not automatically resubmit your information for you.

To resubmit your information and view this Web page, click the Refresh
button.

Nov 17 '05 #12
This is a form (ASP.NET webform). Is this what you mean? Sorry, ASP.NET /
web development is new to me.

"Michael Tissington" <mi*****@nospam.com> wrote in message
news:e0**************@TK2MSFTNGP11.phx.gbl...
Like other have said - you ONLY will get this when a FORM is involved on the page.

--
Michael Tissington
Oaklodge Technologies
http://www.oaklodge.com/technology

"VB Programmer" <gr*********@go-intech.com> wrote in message
news:e8**************@TK2MSFTNGP10.phx.gbl...
I know some sites will display the following message if you click on the
BACK button in your browser. How do I implement this feature?

Warning: Page has Expired The page you requested was created using
information you submitted in a form. This page is no longer available.
As a
security precaution, Internet Explorer does not automatically resubmit

your
information for you.

To resubmit your information and view this Web page, click the Refresh
button.


Nov 17 '05 #13

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

4 posts views Thread by John | last post: by
2 posts views Thread by Saverio Tedeschi | last post: by
4 posts views Thread by Nicolás Castagnet | last post: by
5 posts views Thread by jensen bredal | last post: by
10 posts views Thread by kpg | last post: by
3 posts views Thread by Shimon Sim | last post: by
23 posts views Thread by Phil Powell | last post: by
3 posts views Thread by peter | last post: by
reply views Thread by Summercool | last post: by
reply views Thread by devrayhaan | last post: by
reply views Thread by gheharukoh7 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.