File: test/myDialogs.php

Recommend this page to a friend!
  Classes of Joseluis Laso  >  PHP Telegram CLI Wrapper  >  test/myDialogs.php  >  Download  
File: test/myDialogs.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: 4 years ago
Size: 500 bytes
 

Contents

Class file image Download
<?php

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

use
TelegramCliWrapper\TelegramCliWrapper;
use
TelegramCliWrapper\TelegramCliHelper;
use
TelegramCliWrapper\Models\User;

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

echo
"These are my current dialogs" . PHP_EOL .
   
User::getTitles() . PHP_EOL;

$currentDialogs = $t->getDialogList();
foreach (
$currentDialogs as $currentDialog) {
    echo
$currentDialog . PHP_EOL;
}

$t->quit();


For more information send a message to info at phpclasses dot org.