Answer the question
In order to leave comments, you need to log in
How to correctly call the VK method and display the answer?
I log in to VKontakte. All OK. Displays the ID and that the authorization has passed (your code).
Next, I make a request (for example, to a video). By link:
<a href="https://oauth.vk.com/authorize?client_id=ИДМОЕГО_ПРИЛОЖЕНИЯ&scope=video&redirect_uri=http://МОЙСАЙТ/list.php&display=page&response_type=code">Считать видео</a>
<script src="http://vk.com/js/api/openapi.js" type="text/javascript"></script>
<br>
<script language="javascript">
VK.init({
apiId: ИД МОЕГО ПРИЛОЖЕНИЯ
});
VK.Api.call("video.get", function(test) {
if(test.response) {
document.write(test.response[1].photo_320);
document.write(test.response[2].id);
}
});
<br>
</script>
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