A
A
Andrey Hobbs2016-12-12 12:43:28
JavaScript
Andrey Hobbs, 2016-12-12 12:43:28

How to do sharing VK?

Problem with simultaneous sharing and user authorization:

VK.init({apiId: ******});

           VK.Auth.login(function(loginInfo){

                if (!loginInfo || !loginInfo['session']) {
                    return false;
                }

                VK.Api.call('wall.post', {
                    message: document.title,
                    attachments: window.location.href
                }, function(postInfo) {

                    if(postInfo['error'] == undefined){
                        alert('Ура!');
                    } else {
                        alert('Не удалось сохранить информацию о посте.');
                    }

                });

            });

        });

How to bypass pop-up blocker?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question