Ask a Question related to ASP Database, Design and Development.
-
Bari Allen #1
Prevent Page Refresh
How do I prevent a user from going back to a previous page, and also from
refreshing a current page? Forgive me for my ignorance, here; but I've
created a credit card billing page that has a form, which is processed on a
"Thank you form", which processes through Verisign & to a SQL database.
More than occasionally, people are being "double-billed". In some cases,
they are refreshing the page, and other times they're returning "back" to
the submission page, changing the "name on card" to include a middle
initial, or something of the like and resubmitting the form. How do I
prevent the user from doing this? Thanks in advance for your help.
Bari
Bari Allen Guest
-
How can I prevent a button event firing on page refresh?
If a page has a button with event handler private void btnAdd_Click(object sender, System.EventArgs e) { ....... } this event handler fires... -
Prevent data insert on page refresh
After a form is submited and inserted to the database, if the user hits the refresh button the data is again inserted to the database (there is a... -
Force page to refresh/prevent caching
Greetings JGLADNICK. This is referring to your post on CFusion/WebForums of one year ado regarding "Prevent Caching". Have you ever been able to... -
Is there a way to prevent a screen refresh?
Hi everyone, I have this problem where I need to change 4 images on the stage. I use 4 sprites each having a different member. The images are... -
Prevent 'Page has expired' when a client hits back to return to a search page
I have a search page that I want to enable private caching so that when a user hits the back button they dont get the page has expired error. I... -
Ray at #2
Re: Prevent Page Refresh
You cannot prevent people from doing foolish things, but you can prevent
posting-back by means of a refresh by not displaying any response on the
page that processes the form data, i.e.
pagewithform.asp--POST--pagethatprocesses.asp---REDIRECT---pagewiththankyou.
asp
If the person refreshes, all he'll get is the thank you page again.
Aside from that, you'll have to check for double postings in code on the
server.
Ray at work
"Bari Allen" <bari@sos.REMOVETHIS.state.ga.us> wrote in message
news:%23o4OvlJUDHA.2228@tk2msftngp13.phx.gbl...a> How do I prevent a user from going back to a previous page, and also from
> refreshing a current page? Forgive me for my ignorance, here; but I've
> created a credit card billing page that has a form, which is processed on> "Thank you form", which processes through Verisign & to a SQL database.
> More than occasionally, people are being "double-billed". In some cases,
> they are refreshing the page, and other times they're returning "back" to
> the submission page, changing the "name on card" to include a middle
> initial, or something of the like and resubmitting the form. How do I
> prevent the user from doing this? Thanks in advance for your help.
>
> Bari
>
>
Ray at Guest
-
Bari Allen #3
Re: Prevent Page Refresh
I'm looking at all of your suggestions. Thank you. The session code would
also be helpful, if you would post it :)
Bari
"John Beschler" <giles@geewhiz.com> wrote in message
news:007201c351f9$09971a30$a301280a@phx.gbl...> I had a similiar problem with one of my sites. What I did
> was store a session variable that controlled whether the
> page would load or not. As soon as the user clicked the
> submit button, I changed the session variable to prevent
> the page from reloading. If you need the details leave a
> note here and I'll pull the code and post it.
>
> John
>
>
>
>> page, and also from> >-----Original Message-----
> >How do I prevent a user from going back to a previous> here; but I've> >refreshing a current page? Forgive me for my ignorance,> is processed on a> >created a credit card billing page that has a form, which> SQL database.> >"Thank you form", which processes through Verisign & to a> billed". In some cases,> >More than occasionally, people are being "double-> returning "back" to> >they are refreshing the page, and other times they're> include a middle> >the submission page, changing the "name on card" to> form. How do I> >initial, or something of the like and resubmitting the> your help.> >prevent the user from doing this? Thanks in advance for> >
> >Bari
> >
> >
> >.
> >
Bari Allen Guest
-
John Beschler #4
Re: Prevent Page Refresh
In the form page (data entry)
Session("OK2Pro") = True
In the process page:
if Session("OK2Pro") <> true then
response.redirect("default.asp")
else
Session("OK2Pro") = False
End if
When the user clicks the submit button, the first thing
the process page does is set the session variable to
False. Then if the user clicks the back button, Session
("OK2Pro") will be false and the user will be redirected
to the main page if they click submit a second time.
This also prevents the user from updating data on the
server if they leave their browser open on the form page
for longer than the session timeout value. Since Session
("OK2Pro") will be empty after session timeout, the user
will be redirected to the main page.
session code would>-----Original Message-----
>I'm looking at all of your suggestions. Thank you. Thedid>also be helpful, if you would post it :)
>Bari
>
>"John Beschler" <giles@geewhiz.com> wrote in message
>news:007201c351f9$09971a30$a301280a@phx.gbl...>> I had a similiar problem with one of my sites. What Iignorance,>> was store a session variable that controlled whether the
>> page would load or not. As soon as the user clicked the
>> submit button, I changed the session variable to prevent
>> the page from reloading. If you need the details leave a
>> note here and I'll pull the code and post it.
>>
>> John
>>
>>
>>
>>>> page, and also from>> >-----Original Message-----
>> >How do I prevent a user from going back to a previous>> >refreshing a current page? Forgive me for mywhich>> here; but I've>> >created a credit card billing page that has a form,to a>> is processed on a>> >"Thank you form", which processes through Verisign &for>> SQL database.>> billed". In some cases,>> >More than occasionally, people are being "double->> returning "back" to>> >they are refreshing the page, and other times they're>> include a middle>> >the submission page, changing the "name on card" to>> form. How do I>> >initial, or something of the like and resubmitting the>> >prevent the user from doing this? Thanks in advance>>> your help.>> >
>> >Bari
>> >
>> >
>> >.
>> >
>
>.
>John Beschler Guest



Reply With Quote

