PHP Classes

File: test/server-sample.php

Recommend this page to a friend!
  Classes of Joseluis Laso   PHP Telegram CLI Wrapper   test/server-sample.php   Download  
File: test/server-sample.php
Role: Example script
Content type: text/plain
Description: Example script
Class: PHP Telegram CLI Wrapper
Send messages and other commands to Telegram users
Author: By
Last change:
Date: 8 years ago
Size: 534 bytes
 

Contents

Class file image Download
<?php

include_once __DIR__ . '/../vendor/autoload.php';

use
TelegramCliWrapper\TelegramCliWrapper;
use
TelegramCliWrapper\TelegramCliHelper;

$th = TelegramCliHelper::getInstance();
$t = new TelegramCliWrapper($th->getSocket(), $th->isDebug());

// this is only a skeleton, if you consider to provide services to your users through telegram, please take a look over
// the file /public/check.php in order to see how to solve easily
// this file has to be used to listen to users and execute the actions ("orders") that we understand