Save and Delete Data
-
Hello Everybody For Online Ordering System there is some criteria like 1. Add Product into Shopping Cart (product.aspx) 2. Shipping Address (shipping.aspx) 3. Make Payments (payments.aspx) 4. Confirmation (confirmation) As Navaneeth said that keep order information into session table is not a good idea. Now I facing some problem to keep pre-order information into tempOrder data table. So I need to know how will I handle the following information. 1. After adding product into shopping cart if the customer close the window then how will I delete that order information. (i do have custID into tempOrder table). How do I know browser is closed by customer or there is an internet connection problem. 2. All those 4 criteria has to be success before placing an order. 3. Mean anything happen before that time I have to delete order information for that customer Please give me some idea. Thanks in Advance
Sarfarj Ahmed
-
Hello Everybody For Online Ordering System there is some criteria like 1. Add Product into Shopping Cart (product.aspx) 2. Shipping Address (shipping.aspx) 3. Make Payments (payments.aspx) 4. Confirmation (confirmation) As Navaneeth said that keep order information into session table is not a good idea. Now I facing some problem to keep pre-order information into tempOrder data table. So I need to know how will I handle the following information. 1. After adding product into shopping cart if the customer close the window then how will I delete that order information. (i do have custID into tempOrder table). How do I know browser is closed by customer or there is an internet connection problem. 2. All those 4 criteria has to be success before placing an order. 3. Mean anything happen before that time I have to delete order information for that customer Please give me some idea. Thanks in Advance
Sarfarj Ahmed
Sarfaraj Ahmed wrote:
1. After adding product into shopping cart if the customer close the window then how will I delete that order information. (i do have custID into tempOrder table). How do I know browser is closed by customer or there is an internet connection problem.
There is no way to know when a browser window is closed. You can do couple of tricks though 1- Set a JS timer on the client, when the timer is set, make a call to your server to end the session, then you can clean tempTable entry for the given custID. 2-Time Stamp your tempTable entry, then run a job on given interval to wipe out all expired records 3-On SessionEnd, clean your tempTable entries for the given custID
Yusuf
-
Sarfaraj Ahmed wrote:
1. After adding product into shopping cart if the customer close the window then how will I delete that order information. (i do have custID into tempOrder table). How do I know browser is closed by customer or there is an internet connection problem.
There is no way to know when a browser window is closed. You can do couple of tricks though 1- Set a JS timer on the client, when the timer is set, make a call to your server to end the session, then you can clean tempTable entry for the given custID. 2-Time Stamp your tempTable entry, then run a job on given interval to wipe out all expired records 3-On SessionEnd, clean your tempTable entries for the given custID
Yusuf
Dear Yusuf Thank you very much for your help Regards Sarfaraj
Sarfarj Ahmed
-
Dear Yusuf Thank you very much for your help Regards Sarfaraj
Sarfarj Ahmed
I'm not sure if you can use Ajax and onunload enent