当前位置: 首页 > 知识库问答 >
问题:

授权网点ARB网站第二次付款通知

巫化
2023-03-14

我已经创建了一个授权的网络ARB会员。我可以在运行ARB脚本时创建任何成员。但在第二次付款后我怎么知道呢。除了电子邮件之外,还有其他方式吗?在ARB期间的每笔交易发生后,授权的网络将直接从授权的网络直接抛出一个url,我网站上的会员资格将在我的网站上自动更新。

这是我下载ARB代码并实现订阅的URL。

http://developer.authorize.net/downloads/samplecode/

以下是HTML和PHP代码。

超文本标记语言

 <form method="post" action="subscription_create.php">
            <table width="35%" border="0">
                <tr>
                    <td>
                        <b><font size="2" face="arial">Create Subscription</font><br>
                        <br></b>
                    </td>
                    <td></td>
                </tr>
                <tr>
                    <td>
                        <font size="2" face="arial">Reference Id</font>
                    </td>
                    <td>
                        <input type="text" name="refId" value=''> <font size="1" face="arial">MAX = 20 chars</font>
                    </td>
                </tr>
                <tr>
                    <td>
                        <font size="2" face="arial">Subscription Name</font>
                    </td>
                    <td>
                        <input type="text" name="name" value=''>
                    </td>
                </tr>
                <tr>
                    <td>
                        <font size="2" face="arial">Subscription Length</font>
                    </td>
                    <td>
                        <input type="text" name="length" value=''> <font size="1" face="arial">1 - 12 or 7 - 365</font>
                    </td>
                </tr>
                <tr>
                    <td>
                        <font size="2" face="arial">Subscription Unit</font>
                    </td>
                    <td>
                        <input type="text" name="unit" value=''> <font size="1" face="arial">months or days</font>
                    </td>
                </tr>
                <tr>
                    <td>
                        <font size="2" face="arial">Start Date</font>
                    </td>
                    <td>
                        <input type="text" name="startDate" value=''> <font size="1" face="arial">YYYY-MM-DD</font>
                    </td>
                </tr>
                <tr>
                    <td>
                        <font size="2" face="arial">Total Occurrences</font>
                    </td>
                    <td>
                        <input type="text" name="totalOccurrences" value=''> <font size="1" face="arial">MAX = 9999</font>
                    </td>
                </tr>
                <tr>
                    <td>
                        <font size="2" face="arial">Trial Occurrences</font>
                    </td>
                    <td>
                        <input type="text" name="trialOccurrences" value=''> <font size="1" face="arial">0 = None. MAX = 99</font>
                    </td>
                </tr>
                <tr>
                    <td>
                        <font size="2" face="arial">Amount</font>
                    </td>
                    <td>
                        <input type="text" name="amount" value=''>
                    </td>
                </tr>
                <tr>
                    <td>
                        <font size="2" face="arial">Trial Amount</font>
                    </td>
                    <td>
                        <input type="text" name="trialAmount" value=''> <font size="1" face="arial">0 = None</font>
                    </td>
                </tr>
                <tr>
                    <td>
                        <font size="2" face="arial">Credit Card Number</font>
                    </td>
                    <td>
                        <input type="text" name="cardNumber" value=''>
                    </td>
                </tr>
                <tr>
                    <td>
                        <font size="2" face="arial">Expiration Date</font>
                    </td>
                    <td>
                        <input type="text" name="expirationDate" value=''> <font size="1" face="arial">YYYY-MM</font>
                    </td>
                </tr>
                <tr>
                    <td>
                        <font size="2" face="arial">First Name</font>
                    </td>
                    <td>
                        <input type="text" name="firstName" value=''>
                    </td>
                </tr>
                <tr>
                    <td>
                        <font size="2" face="arial">Last Name</font>
                    </td>
                    <td>
                        <input type="text" name="lastName" value=''>
                    </td>
                </tr>
                <tr>
                    <td>
                        <br>
                        <input type="submit" name="submit" value="Submit"><input type="reset" name="reset" value="Reset">
                    </td>
                    <td></td>
                </tr>
            </table>
        </form>

Php代码

 include ("authnetfunction.php");

    $amount = $_POST["amount"];
    $refId = $_POST["refId"];
    $name = $_POST["name"];
    $length = $_POST["length"];
    $unit = $_POST["unit"];
    $startDate = $_POST["startDate"];
    $totalOccurrences = $_POST["totalOccurrences"];
    $trialOccurrences = $_POST["trialOccurrences"];
    $trialAmount = $_POST["trialAmount"];
    $cardNumber = $_POST["cardNumber"];
    $expirationDate = $_POST["expirationDate"];
    $firstName = $_POST["firstName"];
    $lastName = $_POST["lastName"];

    $loginname = [LOGIN-NAME];
    $transactionkey = [TRANSACTION-KEY];

    echo "Results <br><br>";


    $content =
            "<?xml version=\"1.0\" encoding=\"utf-8\"?>" .
            "<ARBCreateSubscriptionRequest xmlns=\"AnetApi/xml/v1/schema/AnetApiSchema.xsd\">" .
            "<merchantAuthentication>".
            "<name>" . $loginname . "</name>".
            "<transactionKey>" . $transactionkey . "</transactionKey>".
            "</merchantAuthentication>".
            "<refId>" . $refId . "</refId>".
            "<subscription>".
            "<name>" . $name . "</name>".
            "<paymentSchedule>".
            "<interval>".
            "<length>". $length ."</length>".
            "<unit>". $unit ."</unit>".
            "</interval>".
            "<startDate>" . $startDate . "</startDate>".
            "<totalOccurrences>". $totalOccurrences . "</totalOccurrences>".
            "<trialOccurrences>". $trialOccurrences . "</trialOccurrences>".
            "</paymentSchedule>".
            "<amount>". $amount ."</amount>".
            "<trialAmount>" . $trialAmount . "</trialAmount>".
            "<payment>".
            "<creditCard>".
            "<cardNumber>" . $cardNumber . "</cardNumber>".
            "<expirationDate>" . $expirationDate . "</expirationDate>".
            "</creditCard>".
            "</payment>".
            "<billTo>".
            "<firstName>". $firstName . "</firstName>".
            "<lastName>" . $lastName . "</lastName>".
            "</billTo>".
            "</subscription>".
            "</ARBCreateSubscriptionRequest>";



    $response = send_request_via_curl($host,$path,$content);




    if ($response)
    {
        list ($refId, $resultCode, $code, $text, $subscriptionId) =parse_return($response);


        echo " Response Code: $resultCode <br>";
        echo " Response Reason Code: $code<br>";
        echo " Response Text: $text<br>";
        echo " Reference Id: $refId<br>";
        echo " Subscription Id: $subscriptionId <br><br>";
        echo " Data has been written to data.log<br><br>";
        echo $loginname;
        echo "<br />";
        echo $transactionkey;
        echo "<br />";

      echo "amount:";
      echo $amount;
      echo "<br \>";

      echo "refId:";
      echo $refId;
      echo "<br \>";

      echo "name:";
      echo $name;
      echo "<br \>";

      echo "amount: ";
      echo $HTTP_POST_VARS[amount];
      echo "<br \>";
      echo "<br \>";
      echo $content;
      echo "<br \>";
      echo "<br \>";

    }
    else
    {
        echo "Transaction Failed. <br>";
    }

共有1个答案

史烈
2023-03-14

Silent Post*是授权. Net版本的Paypal IPN。无论何时付款,无论付款方式如何,都会通过Silent Post发送通知,通知商家付款。

*我是那篇文章的作者

 类似资料:
  • 我正在使用PayPal快速结帐,我需要做的是稍后单独授权和捕获付款,我目前的PayPal流程是, 1) 我使用以下代码创建付款: Paypal将订单信息和重定向返回给我,我将用户重定向到

  • 我有问题让贝宝接受从我的应用程序的实时支付。我正在使用一个Azure服务器,用C#编写代码,带有一个基于Xamarin的Android客户端应用程序。我可以得到所有工作与贝宝沙箱,但它失败时,我切换到实时凭据。下面是我的付款流程: 1)在我的Android应用程序中,启动PayPal应用程序授权支付。这返回一个授权代码。该代码类似于C21AAHHVXYJKTRK82SOMDGL6SSQD85LLM

  • 我很高兴。Android中的网络支付网关。 但在上面的sdk中,我并没有传递大量的加密传输。有谁能帮我在授权的情况下进行简单的支付交易吗。net android。 提前感谢。

  • 准备工作 微哨登录是基于 OAuth 2.0 协议标准构建的第三方网站应用授权登录系统。用户在微哨门户中访问第三方网站时,网站应用可通过网页授权机制,获取用户基本信息,进而实现业务逻辑。 在进行微哨登录接入之前,开发者需要在微哨开放平台注册开发者帐号,并拥有一个已审核通过的网站应用,获得相应的 App Key 和 App Secret ;或者通过学校管理员创建校内应用,并获得相应的 App Key

  • 第三方服务商网页授权有两种: 第三方应用网页授权 企业网页授权 创建实例: use EasyWeChat\work\Application; $config = [ 'corp_id' => 'xxxxxxxxxxxxxxxxx', 'secret' => 'xxxxxxxxxx', // 应用的 secret ]; $app = new Application($conf

  • 此文档为企业微信内部应用开发的网页授权 企业微信官方文档 创建实例: use EasyWeChat\work\Application; $config = [ 'corp_id' => 'xxxxxxxxxxxxxxxxx', 'secret' => 'xxxxxxxxxx', // 应用的 secret ]; $app = new Application($config)