Php 从migs支付捕获错误消息

Php 从migs支付捕获错误消息,php,mastercard,Php,Mastercard,我为我的网站创建的MIGS支付工具有问题。当用户在migs服务器上遇到错误(付款未成功运行)时,我如何知道它是否遇到此类错误 以下是我使用的参数(将我的链接替换为示例链接): 我如何知道它是否失败,因为无论是付款成功还是付款失败,它都会转到同一个返回URL。我是否可以设置另一个链接,如果交易失败,它将转到该链接?如VPC手册中所述-“使用VPC_ReturnURL字段中指定的Internet浏览器重定向将交易响应返回到您的网站。DR将始终为在线商店提供一个安全哈希,以检查数据完整性。” 基本上,

我为我的网站创建的MIGS支付工具有问题。当用户在migs服务器上遇到错误(付款未成功运行)时,我如何知道它是否遇到此类错误

以下是我使用的参数(将我的链接替换为示例链接):


我如何知道它是否失败,因为无论是付款成功还是付款失败,它都会转到同一个返回URL。我是否可以设置另一个链接,如果交易失败,它将转到该链接?

如VPC手册中所述-“使用VPC_ReturnURL字段中指定的Internet浏览器重定向将交易响应返回到您的网站。DR将始终为在线商店提供一个安全哈希,以检查数据完整性。”

基本上,它抛出一个名为vpc_TxnResponseCode的
$GET
变量,其中:

The merchant application receipting function needs to be able to calculate the secure hash signature in the Transaction Response to determine if the signature received is valid for the receipt data. It has to handle:
• Incorrect secure hash signatures
• Successful transactions
• If vpc_TxnResponseCode code is equal to '0' then the transaction was completed successfully and you can display a receipt to the cardholder.
• Declined transactions
• If vpc_TxnResponseCode is equal to '1', '2', '3', '4', or '5' the transaction has been declined and this needs to be conveyed back to the cardholder.
• Error Conditions –
• If vpc_TxnResponseCode equals '7' or '8' an error has occurred
• Other values may also indicate an error has occurred
• Further details for error conditions can be gathered by examining the vpc_Message field so a decision can be made as to the next step.
All four of these conditions are responses that can be returned from the Virtual Payment Client.

我希望这能帮助其他也在使用MIG开发应用程序的人。我很幸运,在我告诉一位朋友我正在寻找有关MIGS回复的答案后,他能给我这个资源。

幸好我从一位在线朋友那里得到了一本MIGS支付手册,并找到了答案。我会尽快把它寄出去。
The merchant application receipting function needs to be able to calculate the secure hash signature in the Transaction Response to determine if the signature received is valid for the receipt data. It has to handle:
• Incorrect secure hash signatures
• Successful transactions
• If vpc_TxnResponseCode code is equal to '0' then the transaction was completed successfully and you can display a receipt to the cardholder.
• Declined transactions
• If vpc_TxnResponseCode is equal to '1', '2', '3', '4', or '5' the transaction has been declined and this needs to be conveyed back to the cardholder.
• Error Conditions –
• If vpc_TxnResponseCode equals '7' or '8' an error has occurred
• Other values may also indicate an error has occurred
• Further details for error conditions can be gathered by examining the vpc_Message field so a decision can be made as to the next step.
All four of these conditions are responses that can be returned from the Virtual Payment Client.