Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Page Expires

Status
Not open for further replies.

xloop

Programmer
Nov 12, 2001
86
0
0
GB
Does anyone know how to make a page expire..

Now, whats happening is this..

The user is selecting various values on the page and then submitting the results to itself, however, if the user happens to press Refresh on the browser it automatically submits the information again. It's causing headaches because it's submitting negative figures.

Is there a way to create a page that can't be manually refreshed?

Thanks
 
You said..

if the user happens to press Refresh on the browser it automatically submits the information again. It's causing headaches because it's submitting negative figures

It is not understood properly,
However you can disable the tool bar ??

Rushi Shroff
 
Forget the negative figures bit.

Can't use a popup window unfortunately.

Basically im submitting a number to the page and this number then subtracts from a number in the database. And if this number is greater than the number in the database it puts it in negative figures.

Yes, i could write a procedure around it check the DB, however, it's not all that straight forward.

Any ideas?
 
After you perform the submit action,while returning send querystring or hidden field setting some value indicating that once the action has been peformed..

This is the best way..Or set the flag in database..after action got performed..

That is ALL what i can suggest you..

Rushi Shroff
 
Try using a Session variable. Set a SessionVariable named PageVisited, or something like that. Then in your ASP code you could write If PageVisited Then Do Something else like redirect.

If you want to store Session information in a Database, there is a great Object that I use for my sites. You can download it here.

Good luck. Hope this helps.

Osie Brown
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top