Category : telegram-webhook

I have a Telegram bot written in PHP. It sends large list of person details. My problem is that I cant send all data. $input = file_get_contents(‘php://input’); $update = json_decode($input); $message = $update->message; $chat_id = $message->chat->id; $file = file_get_contents(‘a_very_long_lidt.txt’); //this is the file i want to send $token = ‘TOKEN’; file_get_contents("https://api.telegram.org/bot$token/sendMessage?chat_id=$chat_id&text=$file"); //sending the whole file ..

Read more

Before using windows I was Ubuntu User. When I used ngrok on ubuntu, It automatically accesses to /var/www/html directory, afetr this I can easily open php file which telegram bot codes to see result. Now on Windows, I am using openserver. Openserever domains directory for php files like /var/www/html in ubuntu. I installed ngrok.exe. when ..

Read more

I’m using longman/telegram-bot package at my Yii2 project. class GenericmessageCommand extends SystemCommand { /** * @var string */ protected $name = ‘genericmessage’; /** * @var string */ protected $description = ‘Handle generic message’; /** * @var string */ protected $version = ‘1.0.0’; /** * Main command execution * * @return ServerResponse */ public function execute(): ..

Read more