A
A
Azama Vaniev2020-09-19 18:27:34
Python
Azama Vaniev, 2020-09-19 18:27:34

How to change the telegram bot photo to a new one?

I’m writing a telegram bot, the bot sends a welcome photo and offers a product
5f6622648931a195402920.jpeg
I want to make it so that when you click on the product, the photo and text change, I solved the problem with the text, but the problem with the photo 5f6622c89ad83152851949.jpeg
is the code itself
5f66234a1841b860590640.jpeg5f66235018f20862725435.jpeg5f662356d2c48187223856.jpeg

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Mikhail Krostelev, 2020-09-19
@twistfire92

You send a picture separately, a text separately. Using the send_photo method, you can send not only a photo, but also a caption to it, and even a block of buttons. And then change the photo using the edit_message_media method .

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question