The second way. As soon as user click submit button, submit a processing job (new thread) and display a waiting page. This waiting page uses refresh tag to check the status of the processing on the server and stays in browser. When the processing is done the thread servlet sends a confirmation page back.
Bruce Mike Burdette wrote:
I have a bill payment web site which has a payment information form (credit card number, expiration date, etc...) on a page which stays displayed after the user clicks "Submit Payment". The confirmation page is not shown until the transaction has completed which may take as long as 10- seconds. I am having trouble with users clicking a second time and submitting two payments.I am assuming that I could just redirect the browser to the "Please wait...." page while the credit card processes the request, but how will that page know that the credit card process is done and send the browser to the confirmation page? I know that a lot of sites do this, but can't figure out how it works. I am using Java servlet technology.TIA Mike
As an Amazon Associate we earn from qualifying purchases.
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.