Answer the question
In order to leave comments, you need to log in
How to separate buttons in a telegram bot message?
I can’t figure out how to split the buttons under the message into rows and columns, the bot simply displays a message with buttons in a row (and then more than 8 buttons in a row all fit)
Buttons 4 and 5 need to be in the 2nd row
$inline_keyboard_questions_account = [],
'reply_markup' => inline_keyboard($inline_keyboard_questions_account)
Answer the question
In order to leave comments, you need to log in
$mata["reply_markup"] = json_encode([
"keyboard" => [
,
, // вторая строка
,
]
]);
$inline_keyboard_questions_account = [
[
['text' => '№1', 'callback_data' => 'question 1'],
['text' => '№2', 'callback_data' => 'question 2'],
['text' => '№3', 'callback_data' => 'question 3']
],
[
['text' => '№4', 'callback_data' => 'question 4'],
['text' => '№5', 'callback_data' => 'question 5']
]
];
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question