I have set the code for the cancel button but nothing happens when it is clicked. Any suggestions why? I thought this was the code to set it:
settings(3) = New settingType settings(3).settingName = settingNameEnum.hostedPaymentReturnOptions.ToString settings(3).settingValue = "{""url"": ""http://mysite/training-center/training-locations"", ""urlText"": ""Continue"", ""cancelUrl"": ""http://mysite/training-center/training-schedule"", ""cancelUrlText"": ""Cancel""}"
It works for the "Continue" button which appears on the receipt page but the "Cancel" button that is shown on the payment page ("Pay" and "Cancel" buttons are shown) does nothing.
Thanks.
02-27-2018 03:48 PM - edited 02-27-2018 03:52 PM
Any suggestions?
03-07-2018 03:32 PM
After looking the code it seems SettingValue got messed up, Please check your request when goes on network, if it follow below structure:-
JSON:-
"hostedPaymentSettings": {
"setting": [{
"settingName": "hostedPaymentReturnOptions",
"settingValue": "{\"showReceipt\": true, \"url\": \"https://mysite.com/receipt\", \"urlText\": \"Continue\", \"cancelUrl\": \"https://mysite.com/cancel\", \"cancelUrlText\": \"Cancel\"}"
}, {
"settingName": "hostedPaymentPaymentOptions",
"settingValue": "{\"cardCodeRequired\": false, \"showCreditCard\": true, \"showBankAccount\": true}"
}]
}
XML:-
<hostedPaymentSettings>
<setting>
<settingName>hostedPaymentReturnOptions</settingName>
<settingValue>{"showReceipt": true, "url":"https://mysite.com/receipt","urlText":"Continue","cancelUrl":"https://mysite.com/cancel","cancelUrlText":"CancelText"}</settingValue>
</setting>
<setting>
<settingName>hostedPaymentPaymentOptions</settingName>
<settingValue>{"cardCodeRequired": true, "showCreditCard": true, "showBankAccount": true}</settingValue>
</setting>
</hostedPaymentSettings>
Please refer here:-
https://developer.authorize.net/api/reference/features/accept_hosted.html
I hope it will help.
Thanks,
03-07-2018 05:24 PM