我们如何使用Paypal Payflow专业版帐户在同一网站上退还扣除额. [英] How can we return deduct amount in same website by using Paypal Payflow pro account.

查看:106
本文介绍了我们如何使用Paypal Payflow专业版帐户在同一网站上退还扣除额.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

How can we return deduct amount in same website by using Paypal Payflow pro account.





I am using Paypal Payflow pro account for one of my application. It does transaction but doesn''t return deduct amount details. I am using first time Paypal Payflow account. So if anybody have done such kind of work before kindly share with me.

推荐答案

Hi to all i have done this, Kindly check my solution:



Hi to all i have done this, Kindly check my solution:



protected NameValueCollection httpRequestVariables()
   {
       var post = Request.Form;       //


_POST var get = Request.QueryString; //
_POST var get = Request.QueryString; //


_GET 返回合并(发布,获取); }
_GET return Merge(post, get); }





 protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            string output = "";
            if (httpRequestVariables()["RESULT"] != null)
            {
                HttpContext.Current.Session["payflowresponse"] = httpRequestVariables();
                output += "<script type=\"text/javascript\">window.top.location.href = \"" + url + "\";</script>";
                BodyContentDiv.InnerHtml = output;
                return;
            }

var payflowresponse = HttpContext.Current.Session["payflowresponse"] as NameValueCollection;
            if (payflowresponse != null)
            {
                HttpContext.Current.Session["payflowresponse"] = null;

                bool success = payflowresponse["RESULT"] == "0";
                if (success)
                {
                    output += "<span style="font-family:sans-serif;font-weight:bold;">Transaction approved! Thank you for your order.</span>";
                }
                else
                {
                    output += "<span style="font-family:sans-serif;">Transaction failed! Please try again with another payment method.</span>";
                }





public string print_r(Object obj)
       {
           string output = "<pre>\n";
           if (obj is NameValueCollection)
           {
               NameValueCollection nvc = obj as NameValueCollection;

               output += "RESULT" + "=" + nvc["RESULT"] + "\n";
               output += "PNREF" + "=" + nvc["PNREF"] + "\n";
               output += "RESPMSG" + "=" + nvc["RESPMSG"] + "\n";
               output += "AUTHCODE" + "=" + nvc["AUTHCODE"] + "\n";
               output += "CVV2MATCH" + "=" + nvc["CVV2MATCH"] + "\n";
               output += "AMT" + "=" + nvc["AMT"] + "\n";

           }
           else
           {
               output += "UNKNOWN TYPE";
           }
           output += "";
       }


这篇关于我们如何使用Paypal Payflow专业版帐户在同一网站上退还扣除额.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆