StringBuilder PayPalLink = new StringBuilder("https://www.paypal.com/cgi-bin/webscr");
PayPalLink.Append("?cmd=_ext-enter");
PayPalLink.Append("&redirect_cmd=_xclick");
PayPalLink.Append("&custom=" + System.Uri.EscapeDataString(OurReference));
PayPalLink.Append("&business=" + ConfigurationManager.AppSettings["OurPayPalAccount"]);
PayPalLink.Append("&item_name=" + System.Uri.EscapeDataString(ItemName));
PayPalLink.Append("&amount=" + System.Uri.EscapeDataString(ItemAmount.ToString()));
PayPalLink.Append("&no_shipping=1");
PayPalLink.Append("&no_note=1");
PayPalLink.Append("¤cy_code=" + Currency);
PayPalLink.Append("&bn=" + System.Uri.EscapeDataString("PP-BuyNowBF"));
PayPalLink.Append("&cancel_return=" + System.Uri.EscapeDataString(CancelReturnUrl));
PayPalLink.Append("&return=" + System.Uri.EscapeDataString(SuccessReturnUrl);
PayPalLink.Append("&rm=" + System.Uri.EscapeDataString("2"));
PayPalLink.Append("&email=" + System.Uri.EscapeDataString(Email));
PayPalLink.Append("&first_name=" + System.Uri.EscapeDataString(Forename));
PayPalLink.Append("&last_name=" + System.Uri.EscapeDataString(Surname));
PayPalLink.Append("&address1=" + System.Uri.EscapeDataString(Address1));
PayPalLink.Append("&address2=" + System.Uri.EscapeDataString(Address2));
PayPalLink.Append("&city=" + System.Uri.EscapeDataString(TownCity));
PayPalLink.Append("&state=" + System.Uri.EscapeDataString(CountyState));
PayPalLink.Append("&zip=" + System.Uri.EscapeDataString(Postcode));
PayPalLink.Append("&country=" + System.Uri.EscapeDataString(CountryCode));
PayPalLink.Append("&charset=" + System.Uri.EscapeDataString("UTF-8"));
Response.Redirect(PayPalLink.ToString());
|