Sorry, I would like to know why my telegram bot is not responding to my callback_query. I feel like I did everything correctly but I really don't understand where the error is.
edit: When I click on the message button, it should send me the callback_data, which is read by the callback_query, but this doesn't happen, why?
How I set the query variables.
//callback
$update = json_decode(file_get_contents('php://input'), TRUE);
$callback = $update['callback_query'];
$callbackUser = $callback['from']['username'];
$callbackID = $callback['id'];
$callbackChatID = $callback['from']['id'];
$callbackData = $callback['data'];
Small if to see if it works.
if ($callbackData == 'testo') {
SMG($ChatID, "funziona");
}
Button to send the callback_data.
$minersBtn = [[["text" => "$miningBtn", "callback_data" => "$miningStatus"],["text" => "Indietro⬅️", "callback_data" => "testo"]]];