<?php
header("Content-Type: text/html; charset=utf-8");
$request_params = [
'code' => '
var a = [];
a.push(1);
a.push(2);
a.push(3);
a[2] = 2;
return a;
',
'access_token' => '80dfb7f0cf64a67467c02b34'
];
$url ="https://api.vk.com/method/execute?" . http_build_query($request_params);
$result = file_get_contents($url);
$array = json_decode($result);
print_r($array);