Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > expiring pages

Reply
Thread Tools

expiring pages

 
 
Gav
Guest
Posts: n/a
 
      01-02-2004
Hi,
I have a form which sibmits data to another page. Trouble is when the user
refreshes the page it resubmits all the data again.

Is there anyway to expire the page immediatly so this cant happen??

gav


 
Reply With Quote
 
 
 
 
Steven Burn
Guest
Posts: n/a
 
      01-02-2004
<%Response.Clear%>

--
Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

Disclaimer:
I know I'm probably wrong, I just like taking part ;o)


Gav <(E-Mail Removed)> wrote in message
news:lgeJb.42$(E-Mail Removed)...
> Hi,
> I have a form which sibmits data to another page. Trouble is when the user
> refreshes the page it resubmits all the data again.
>
> Is there anyway to expire the page immediatly so this cant happen??
>
> gav
>
>



 
Reply With Quote
 
 
 
 
Dave Anderson
Guest
Posts: n/a
 
      01-02-2004
"Gav" wrote:
>
> I have a form which sibmits data to another page. Trouble
> is when the user refreshes the page it resubmits all the
> data again.
>
> Is there anyway to expire the page immediatly so this cant
> happen??


The process and redirect model is well suited for this. You can implement it
with or without post-back. Here are a couple of stripped down examples:

Process and redirect with post-back ---------------------------
[p1.asp]
<%
If Request.Form.Count AND (validation criteria) > 0 Then
{ process data, assign cookie or session info }
Response.Redirect("p2.asp")
End If
%>
...
<FORM ACTION="p1.asp">

[p2.asp]
<% { read cookie/session data, process page } %>


Process and redirect without post-back ------------------------
[p1.asp]
<FORM ACTION="p2.asp">

[p2.asp]
<%
If (validation criteria) Then
{ process data, assign cookie or session info }
Response.Redirect("p3.asp")
Else
Response.Redirect("p1.asp")
End If
%>

[p3.asp]
<% { read cookie/session data, process page } %>



--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use
of this email address implies consent to these terms. Please do not contact
me directly or ask me to contact you directly for assistance. If your
question is worth asking, it's worth posting.


 
Reply With Quote
 
Brynn
Guest
Posts: n/a
 
      01-03-2004
Yeah, 3 files

form.asp
formaction.asp (with redirect to...)
formconfirmation.asp

also, then they hit the back button, it will take them back to the
form, instead of formaction



On Fri, 2 Jan 2004 08:29:35 -0600, "Dave Anderson"
<(E-Mail Removed)> wrote:

>"Gav" wrote:
>>
>> I have a form which sibmits data to another page. Trouble
>> is when the user refreshes the page it resubmits all the
>> data again.
>>
>> Is there anyway to expire the page immediatly so this cant
>> happen??

>
>The process and redirect model is well suited for this. You can implement it
>with or without post-back. Here are a couple of stripped down examples:
>
>Process and redirect with post-back ---------------------------
>[p1.asp]
><%
> If Request.Form.Count AND (validation criteria) > 0 Then
> { process data, assign cookie or session info }
> Response.Redirect("p2.asp")
> End If
>%>
> ...
> <FORM ACTION="p1.asp">
>
>[p2.asp]
><% { read cookie/session data, process page } %>
>
>
>Process and redirect without post-back ------------------------
>[p1.asp]
> <FORM ACTION="p2.asp">
>
>[p2.asp]
><%
> If (validation criteria) Then
> { process data, assign cookie or session info }
> Response.Redirect("p3.asp")
> Else
> Response.Redirect("p1.asp")
> End If
>%>
>
>[p3.asp]
><% { read cookie/session data, process page } %>
>
>
>
>--
>Dave Anderson
>
>Unsolicited commercial email will be read at a cost of $500 per message. Use
>of this email address implies consent to these terms. Please do not contact
>me directly or ask me to contact you directly for assistance. If your
>question is worth asking, it's worth posting.
>
>


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Main Mode IKE expiring , what's next? matteo_cardelli@yahoo.co.uk Cisco 0 08-20-2005 05:00 PM
Expiring certification James MCSD 2 11-10-2004 10:39 PM
Bug in ie5 history handling of expiring pages Lasse Javascript 0 08-29-2003 01:16 PM
Re: MCSD vb6 - is it worth it? MCSD v6 exams expiring in 2004 Davin MCSD 0 06-30-2003 03:26 PM
Re: MCSD vb6 - is it worth it? MCSD v6 exams expiring in 2004 Cindy Winegarden MCSD 0 06-29-2003 07:42 PM



Advertisments