Нужно получить кол-во комментариев к сегодняшним записям и найти кто оставил больше. Для этого нужно несколько раз вызвать метод
do {
$comments_get = getApiMethod('execute.wallGetComments', array(
'owner_id' => '-'.$group_id,
'post_id' => $wall['id'],
'need_likes' => '1',
'count' => '100',
'access_token' => $access_token,
'offset' => $offset
));
$comments_get = json_decode($comments_get, true);
} while (isset($comments_get['error']['error_code']) && $comments_get['error']['error_code'] == 6);
Создал хранимую процедуру, чтобы можно было делать execute, но все равно иногда бывает ошибка №6. Поможет ли помочь, если добавить
while (isset($comments_get['error']['error_code']) && $comments_get['error']['error_code'] == 6)
?