Dipa Ahuja

Dipa Ahuja

  • NA
  • 3.1k
  • 715.3k

how to clear previous page's data?

Oct 20 2009 11:44 AM

hello i am developing e-shopping website
after adding items in cart.aspx...n by clicking on "FINALE PURCHASE" button control goes to the card.aspx
--->click method of cart.aspx
 
protected
void final_Click(object sender, EventArgs e)
{
Session[
"total"] = lbltot.Text.ToString();
Response.Redirect(
"card.aspx");
}

 

 
card.aspx
  Photobucket
by clicking on submit in card.aspx
 

 
protected
void submit_Click(object sender, EventArgs e)
{
Session[
"cno"] = cno.Text.ToString();
Session[
"pwd"] = pwd.Text.ToString();
Response.Redirect(
"balance.aspx");
}

the balance.aspx will show the detail of credit card.. that is card no and available balance... and button for "final purchase"
by clicking on final purchase button in balance.aspx.. it will transferred to "Final.aspx" where the balance is deducted from account..
 
now from final.aspx when user clicks on back button of the web browser it shows the data of balance.aspx.. which should not been shown..
 
in php this problem can be solved by taking form as method="post" bt in this it does not allow to take 2 form tags run at server..
i have take
 <form>

in masterfile.master bt in balance.aspx it dosnt allow to take

Answers (23)