realex-payments-api - 卡支付错误 508 -Realex 支付错误号:61,754
问题描述
我正在使用带有 iframe 的 realex 付款,我可以正确加载付款页面,但是一旦我点击“立即付款”,它就会返回错误:508 消息:处理您的请求时发生错误。请联系您购买商品或服务的商家并引用以下错误号:61,754(大多数情况下它会返回正确的响应字符串,成功和拒绝)但有时会返回上述错误代码)知道什么意思以及如何解决这个问题问题?
<script type='text/javascript'>
function iRedirect(redirectUrl, arg, value) {
console.log(redirectUrl);
try {
var form = $('<form action="' + redirectUrl + '" method="post">' +
'<input type="hidden" name="' + arg + '" value="' + value + '"></input>' + '</form>');
$('body').append(form);
console.log(form);
$(form).submit();
}
catch (e) {
alert(e.message);
}
}
function displayMessage(evt)
{
var message;
try {
var iOrigin = '<%=ConfigurationManager.AppSettings["RealexResponseDomain"] %>';
if (evt.origin == iOrigin) {
message = evt.data.toString();
console.log(message);
if (message.indexOf("Error") == 0) {
var ErrorJsonStr = message.toString().split(":");
var ErrorJsonStr1 = ErrorJsonStr[1].split("<BR>");
var reDirectPath = "{\"" + ErrorJsonStr[0] + "\"" + ":" + "\"" + ErrorJsonStr1[0] + "\"" + "," + "\"" + ErrorJsonStr1[1] + "\"" + ":" + "\"" + ErrorJsonStr[2] + "\"" + "}";
iRedirect("Response.aspx", "JsonStr", encodeURIComponent(reDirectPath));
}
else {
if (isJson(message) == true) {
var message1 = JSON.parse(message);
//alert(message1);
console.log(message1);
if (message1.hasOwnProperty('pas_uuid')) {
iRedirect("Response.aspx", "JsonStr", encodeURIComponent(message.toString()));
}
else {
//check if this transaction is already exist
//do redirect
//alert("not pas_uuid" + message1);
console.log("not pas_uuid" + message1);
}
}
}
//get message and check result
}
else {
console.log("not data");
}
}
catch (err) {
console.log(err.message);
}
}
function isJson(str) {
try {
JSON.parse(str);
}
catch (e)
{
console.log(e.message);
return false;
}
return true;
}
if (window.addEventListener) {
// For standards-compliant web browsers
window.addEventListener("message", displayMessage, false);
}
else {
window.attachEvent("onmessage", displayMessage);
}
</script>
解决方案
在 HPP 上显示此消息的主要情况有两种。
HPP 沙盒环境存在临时问题。
您使用的商家 ID 和帐户启用了 3D Secure 1,但您使用了未启用 3D Secure 的测试卡。
如果您认为不是这些问题中的任何一个,请向我们的支持团队提供发生这种情况的交易的示例订单 ID,他们将能够更详细地查看日志。
推荐阅读
- ansible - 如何在 Ansible Playbook 中发送电子邮件作为条件?
- vba - 表格中的VBA Word下标
- r - R 脚本 - 如何检测推文中的表情符号代码
- python - 解析复杂的字符串
- swift - 如何在表格视图中全局获取标题单元格
- ubuntu - Sails.JS 图像上传在生产中不起作用?工作在开发阶段
- selenium-webdriver - 如何更改临时文件系统路径 selenium 3
- uinavigationcontroller - Flutter - 从导航栏更改后退按钮
- python - Grep 和 pGrep 组成流程
- python - 当终端/IDLE 关闭时,python 是否会释放代码中使用的内存?