asp.net paypal redirect set value to mysql
I have C# windows form application with button to open default web browser and go to url to buy credits using paypal.
As a description for paypal product I set username of user register via my c# application. Paypal button url: (I changed paypal email address to firstname.lastname@example.org because I do not want to reveal my paypal email.)
myProcess.StartInfo.FileName = "https://email@example.com¤cy_code=EUR&amount=" + this.textBox1.Text + "&item_name=" + Form1.sendusername + "";
I need to crate .asp web page for paypal return url. If payment is successful I would like to change value money in mysql database where username is item_name (Form1.sendusername) for old value + new amount.
Mysql database structure: name of mysql database: sqldata name of table: users name of row: money
i guess something like: update money set sqldata.users where username=item_name ....
Can someone provide me with example that I can edit. Please make it simple for me to understand because I am a noob :) Thanks!
Check out the PayPal REST API SDK. There are good, simple, examples on the Github repository.