Answer the question
In order to leave comments, you need to log in
VK Payment API - Why an error?
Good day!
The question will be more understandable to those who have already encountered this topic, the updated payment api from VKontakte.
The page has a button + js.
script type="text/javascript">
function order() {
var params = {
type: 'item',
item: 'item1'
};
VK.callMethod('showOrderBox', params);
}
var callbacksResults = document.getElementById('callbacks');
VK.addCallback('onOrderSuccess', function(order_id) {
callbacksResults.innerHTML += '<br />onOrderSuccess '+order_id;
});
VK.addCallback('onOrderFail', function() {
callbacksResults.innerHTML += '<br />onOrderFail';
});
VK.addCallback('onOrderCancel', function() {
callbacksResults.innerHTML += '<br />onOrderCancel';
});
</script>
<input value="1!" type="button" onclick="order()" />
{"response":{"item_id":125,"title":null,"photo_url":"http:\/\/cs608817.vk.me\/v608817064\/c18b\/vT4MrpS****.jpg","price":5}}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question