Answer the question
In order to leave comments, you need to log in
How to send using the messages.send method?
I make notifications through VK. On behalf of the community to the user. By this code
// Уведомления через ВК
$request = $main->requestVkAPI('messages.send', "user_ids={$ownerId}&title={$groupname}&message={$message}&attachment={$attachments}&access_token={$tokengroup}");
$groupname = urlencode('Новое сообщение в группе:');
$groupInfo = $main->requestVkAPI('groups.getById', "group_ids={$groupId}&fields=name,screen_name,description,photo_100&access_token={$tokenadmin}");
$template->templateSetVar('group_name', htmlspecialchars($groupInfo[0]['name']));
$groupInfo[0]['name']
$groupname = urlencode($groupInfo[0]['name']);
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