0

我正在使用 PayPal 购物车,当我收到来自 eBay 或我的网站的订单时,我会发送一条自动回复消息,感谢客户的订单等。这很好,因为我将它设置在我的电子邮件程序 (Windows Live Mail) 在主题行中包含某些字词时发送回复(例如“收到付款”、“收到付款通知”等)。它就像一个魅力,因为发件人是实际客户的电子邮件地址,即使它来自 PayPal。

然而,现在发件人是“member@paypal.com”,所以我的所有通知都未送达就退回给我。

是否有一种解决方法可以让我将这些自动回复消息发送给我的客户?

感谢您提出的任何想法。

杰克逊

4

2 回答 2

0

您可以设置一个 IPN 脚本来向您的客户发送电子邮件。IPN POST 将包含买家的电子邮件地址。即时付款通知 (IPN) 是一种消息服务,可通知您与 PayPal 交易相关的事件。您可以使用它来自动化后台和管理功能,例如履行订单、跟踪客户以及提供与交易相关的状态和其他信息。您可以在此处找到有关 IPN的更多信息。页面左侧还有一些与 IPN 相关的附加链接,您还可以在此处找到 IPN 的一些示例代码,这些代码可以帮助您入门。

<?php
// Revision Notes
// 11/04/11 - changed post back url from https://www.paypal.com/cgi-bin/webscr to https://ipnpb.paypal.com/cgi-bin/webscr
// For more info see below:
// https://www.x.com/content/bulletin-ip-address-expansion-paypal-services
// "ACTION REQUIRED: if you are using IPN (Instant Payment Notification) for Order Management and your IPN listener script is behind a firewall that uses ACL (Access Control List) rules which restrict outbound traffic to a limited number of IP addresses, then you may need to do one of the following: 
// To continue posting back to https://www.paypal.com  to perform IPN validation you will need to update your firewall ACL to allow outbound access to *any* IP address for the servers that host your IPN script
// OR Alternatively, you will need to modify  your IPN script to post back IPNs to the newly created URL https://ipnpb.paypal.com using HTTPS (port 443) and update firewall ACL rules to allow outbound access to the ipnpb.paypal.com IP ranges (see end of message)."


// read the post from PayPal system and add 'cmd'
$req = 'cmd=_notify-validate';

foreach ($_POST as $key => $value) {
$value = urlencode(stripslashes($value));
$req .= "&$key=$value";
}

// post back to PayPal system to validate

$header = "POST /cgi-bin/webscr HTTP/1.1\r\n";

    // If testing on Sandbox use: 
    // $header .= "Host: www.sandbox.paypal.com:443\r\n";
$header .= "Host: ipnpb.paypal.com:443\r\n";
$header .= "Content-Type: application/x-www-form-urlencoded\r\n";
$header .= "Content-Length: " . strlen($req) . "\r\n\r\n";

    // If testing on Sandbox use:
    //$fp = fsockopen ('ssl://www.sandbox.paypal.com', 443, $errno, $errstr, 30);
$fp = fsockopen ('ssl://ipnpb.paypal.com', 443, $errno, $errstr, 30);

// assign posted variables to local variables
$item_name = $_POST['item_name'];
$item_number = $_POST['item_number'];
$payment_status = $_POST['payment_status'];
$payment_amount = $_POST['mc_gross'];
$payment_currency = $_POST['mc_currency'];
$txn_id = $_POST['txn_id'];
$receiver_email = $_POST['receiver_email'];
$payer_email = $_POST['payer_email'];

//set email variables
$From_email = "From: from@mysite.com";
$Subject_line = "Payment Confirmation";

$email_msg = "Thanks for purchasing my item. Your order will be delivered in 3-4 days. We appreciate your business.";
$email_msg .= "\n\nThe details of your order are as follows:";
$email_msg .= "\n\n" . "Transaction ID: " .  $txn_id ;
$email_msg .= "\n" . "Payment Date: " . $payment_date;

if (!$fp) {
// HTTP ERROR
} else {
fputs ($fp, $header . $req);
while (!feof($fp)) {
$res = fgets ($fp, 1024);
if (strcmp ($res, "VERIFIED") == 0) {
// check the payment_status is Completed
// check that txn_id has not been previously processed
// check that receiver_email is your Primary PayPal email
// check that payment_amount/payment_currency are correct
// process payment

$mail_From = $From_email;
$mail_To = $payer_email;
$mail_Subject = $Subject_line;
$mail_Body = $email_msg;

mail($mail_To, $mail_Subject, $mail_Body, $mail_From);


}
else if (strcmp ($res, "INVALID") == 0) {
// log for manual investigation

$mail_From = $From_email;
$mail_To = $receiver_email;
$mail_Subject = "INVALID IPN POST";
$mail_Body = "INVALID IPN POST. The raw POST string is below.\n\n" . $req;

mail($mail_To, $mail_Subject, $mail_Body, $mail_From);

}
}
fclose ($fp);
}
?>
于 2013-03-28T12:34:09.307 回答
0

自从 PayPal 在 3 月份改变通知方式后,我就一直在与 PayPal 就这个问题“联系”。他们的最后一封信读到:

感谢您就您的通知与我们联系。

我想首先对这种情况持续了这么长时间表示抱歉。我知道自从我最初将您的问题上报以来已经有一段时间了,看到它仍在进行中,我感到很难过。

我再次上​​报了这个问题,并附上一张纸条,要求对以前的上报进行调查。我已要求我的一位主管与您联系以解决您的投诉并为您提供所需的完整解释。这将在 72 小时内完成。

感谢您的时间。

此致 Gemma UK 顶级客户部 PayPal

不用说,四个星期后,我不得不一次又一次地与他们联系,并一次又一次地收到了类似的道歉。

在某个地方,一位 PayPal 操作员将更改的原因解释为:

这种情况发生变化的原因是卖家直接回应买家,而不是在我们的系统内对应,这主要与争议和索赔有关。但是,如果您通过 PayPal 系统做出响应,则会被记录下来。

我无休止地要求他们解释这一点,但无济于事。我将继续用不满的抱怨轰炸他们!

然而,他们知道,不只是我心怀不满,而且作为一个单人乐队,他们担心会占用我的电脑时间。

我的抱怨是:

欧洲服务@paypal.com

于 2013-05-02T15:54:46.753 回答