Answer the question
In order to leave comments, you need to log in
How to copy access_token from address?
I use VKontakte authorization by sending the user to this address
oauth.vk.com/authorize?client_id=<?=$client_id;?>&display=page&redirect_uri=https://oauth.vk.com/blank.html&scope=<?=$scope;?>&response_type=token&v=5.37
oauth.vk.com/blank.html#access_token=0000000000&expires_in=0&user_id=111111
Answer the question
In order to leave comments, you need to log in
$params = array(
'client_id' => $client_id,
'client_secret' => $client_secret,
'code' => $_GET['code'],
'redirect_uri' => $redirect_uri
);
$token = json_decode(file_get_contents('https://oauth.vk.com/access_token' . '?' . urldecode(http_build_query($params))), true);
$token['access_token']
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question