Currently am using this code for paypal integration with my application...
string businessPaypalId = "xyz@gmail.com";
double itemCost = 10.00;
string baseUrl = HttpContext.Current.Request.Url.AbsoluteUri.Replace(HttpContext.Current.Request.Url.PathAndQuery, "") + HttpContext.Current.Request.ApplicationPath;
if (!baseUrl.EndsWith("/"))
baseUrl += "/";
string redirect = "";
redirect += "https://www.sandbox.paypal.com/cgi-bin/webscr?cmd=_xclick&business=" + businessPaypalId;
redirect += "&amount=" + itemCost;
redirect += "&item_number=1";
redirect += "¤cy_code= USD";
redirect += "&return=" + baseUrl + "Completed.aspx";
redirect += "&cancel_return=" + baseUrl + "Cancel.aspx";
redirect += "¬ify_url=" + baseUrl + "Notify.aspx";
return redirect;
But i heared that,we need to use some Gateways for transaction, is it true?? if its true then please any one help me how to use gateways in my application??
thulasiram12...
Member
393 Points
200 Posts
Re: Integration with PayPal in C#
Feb 15, 2012 10:50 AM|LINK
Hi friends...
Currently am using this code for paypal integration with my application...
string businessPaypalId = "xyz@gmail.com"; double itemCost = 10.00; string baseUrl = HttpContext.Current.Request.Url.AbsoluteUri.Replace(HttpContext.Current.Request.Url.PathAndQuery, "") + HttpContext.Current.Request.ApplicationPath; if (!baseUrl.EndsWith("/")) baseUrl += "/"; string redirect = ""; redirect += "https://www.sandbox.paypal.com/cgi-bin/webscr?cmd=_xclick&business=" + businessPaypalId; redirect += "&amount=" + itemCost; redirect += "&item_number=1"; redirect += "¤cy_code= USD"; redirect += "&return=" + baseUrl + "Completed.aspx"; redirect += "&cancel_return=" + baseUrl + "Cancel.aspx"; redirect += "¬ify_url=" + baseUrl + "Notify.aspx"; return redirect; But i heared that,we need to use some Gateways for transaction, is it true?? if its true then please any one help me how to use gateways in my application??abiruban
All-Star
16028 Points
2734 Posts
Re: Integration with PayPal in C#
Feb 15, 2012 05:33 PM|LINK
Hi
no,paypal is the one of the payment gatway but it has been two type of paypal servers one is sandbox server onother one is live server
refer the link..
https://cms.paypal.com/us/cgi-bin/?cmd=_render-content&content_ID=developer/e_howto_api_WPWebsitePaymentsPro
DEMO:
https://www.paypal.com/cgi-bin/webscr?cmd=xpt/Marketing/demo/wppro/WPProDemo-outside
for more detail about paypal integration you download the nopcommerce shopping cart starterkit
In the starterkit integrate all type of payment gatways include paypal
http://www.nopcommerce.com/default.aspx
Thanks...
***DON'T FORGET TO CLICK “MARK AS ANSWER” ON THE POST IF HELPED YOU.