How do I get information back from paypal after the payment is approved?

bethkomodo

New Member
I have an asp.net MVC4 action that has a subscribe paypal button:\[code\]<form action="https://www.sandbox.paypal.com/cgi-bin/webscr" method="post" id="payPalForm"> <input type="hidden" name="item_number" value="http://stackoverflow.com/questions/13714063/@item.Id"> <input type="hidden" name="item_name" value="http://stackoverflow.com/questions/13714063/@item.Name"> <input type="hidden" name="src" value="http://stackoverflow.com/questions/13714063/1">@*Recurring until user cancels*@ <input type="hidden" name="cmd" value="http://stackoverflow.com/questions/13714063/_xclick"> <input type="hidden" name="p3" value="http://stackoverflow.com/questions/13714063/1"> @*Billing cycle amount*@ <input type="hidden" name="t3" value="http://stackoverflow.com/questions/13714063/M"> @*billing cycle period - Month*@ <input type="hidden" name="no_note" value="http://stackoverflow.com/questions/13714063/1"> <input type="hidden" name="business" value="http://stackoverflow.com/questions/13714063/[email protected]">@*Hiva's paypal account*@ <input type="hidden" name="currency_code" value="http://stackoverflow.com/questions/13714063/USD"> <input type="hidden" name="return" value="http://stackoverflow.com/questions/13714063/@returnUrl"> <input type="hidden" name="amount" id="amount" value="http://stackoverflow.com/questions/13714063/@item.Price"> <input type="submit" name="Submit" value="http://stackoverflow.com/questions/13714063/Subscribe"> </form>\[/code\]In the return URL it hits an action where I want to be able to see the form details and whether the payment went through, and all that good stuff. This is what I have:\[code\] public ActionResult PaymentConfirm(FormCollection form) { //if successful, blah blah var user = User.Identity.Name; //Merchant merch = ctx.Merchants.Single(x => x.User.UserName == user); //merch.Plan = plan; return RedirectToAction("Index", "Merchant"); }\[/code\]How can I get this data!
 
Back
Top