telegram-bot-sdk icon indicating copy to clipboard operation
telegram-bot-sdk copied to clipboard

Inline Keyboard web_app

Open HydraCoderX opened this issue 1 year ago • 1 comments

Hi, didnt find anywhere anything about it. But is it possible to open the inapp browser with an inline button?

->row([Keyboard::inlineButton(['text' => 'Book Ads', 'web_app' => 'https://url.com'])]

like this? with the "web_app" or did i muss something?

Greetings

HydraCoderX avatar Apr 27 '23 09:04 HydraCoderX

Hi, didnt find anywhere anything about it. But is it possible to open the inapp browser with an inline button?

->row([Keyboard::inlineButton(['text' => 'Book Ads', 'web_app' => 'https://url.com'])]

like this? with the "web_app" or did i muss something?

Greetings

$inlineLayout = [
    [
        Keyboard::inlineButton([
            'text' => 'Test',
            'web_app' => [
                'url' => 'https://test.ru'
            ]
        ]),
    ]
];

$keyboard = Keyboard::make([
    'inline_keyboard' => $inlineLayout
]);

$this->replyWithMessage([
    'text' => "Text",
    'reply_markup' => $keyboard
]);

mes01 avatar Jun 02 '23 09:06 mes01

$reply_markup = Keyboard::make()
				->inline()
				->row([
					Keyboard::inlineButton([
                        'text' => 'Test',
                        'web_app' => [
                            'url' => 'https://google.com'
                        ]
                    ])
				]);

irazasyed avatar Mar 11 '24 04:03 irazasyed