Scenario: Using Chrome or Safari browsers on a V10 site, the "Confirm" button that transfers you to the external PSP seems to do nothing. Sage and PayPal were affected but probably all external PSP's will be. Other browsers are OK.
Cause: Amazingly, the layouts had been tweaked and a single <strong> tag without a matching </strong> tag in the left hand nav was the cause.
Technical info: Seems that the AJAX code used to fetch the PSP page is very sensitive to errors in the DOM and the return statement marked in red in the following code in function GetPSPFormAndSubmit in actinicextras.js was executed, abandoning the submit.
Cause: Amazingly, the layouts had been tweaked and a single <strong> tag without a matching </strong> tag in the left hand nav was the cause.
Technical info: Seems that the AJAX code used to fetch the PSP page is very sensitive to errors in the DOM and the return statement marked in red in the following code in function GetPSPFormAndSubmit in actinicextras.js was executed, abandoning the submit.
Code:
function GetPSPFormAndSubmit(nPaymentMethod)
{
var ajaxRequest = new ajaxObject(document.location.href.split('?')[0]);
ajaxRequest.callback = function (responseText)
{
if (responseText.substring(0, 6) == "Error:")
{
alert(responseText);
var elemConfirmOrder = document.getElementById("idBtnConfirm");
if (elemConfirmOrder)
{
elemConfirmOrder.value = g_sConfirmOrderInitText;
}
return;
}
//
// Get the placeholder span for the PSP form
//
var elemSpanPSPForm = document.getElementById("idSpanPSPForm");
if (!elemSpanPSPForm)
{
return;
}
elemSpanPSPForm.innerHTML = responseText;
//
// Get the PSP form
//
var elemPSPForm = document.getElementById("idPSPForm");
if (!elemPSPForm)
{
return;
}
//
// Submit the PSP form
//
elemPSPForm.submit();
}
var sParams = "ACTION=GETPSPFORM&PAYMENTMETHOD=" + nPaymentMethod;
var elemPONumber = document.getElementsByName('PAYMENTPONO');
if (elemPONumber.length)
{
sParams += '&PAYMENTPONO=' + escape(elemPONumber[0].value);
}
var elemPayUserDef = document.getElementsByName('PAYMENTUSERDEFINED');
if (elemPayUserDef.length)
{
sParams += '&PAYMENTUSERDEFINED=' + escape(elemPayUserDef[0].value);
}
ajaxRequest.update(sParams, "GET");
}
Comment