本文整理汇总了PHP中Chat::getChat方法的典型用法代码示例。如果您正苦于以下问题:PHP Chat::getChat方法的具体用法?PHP Chat::getChat怎么用?PHP Chat::getChat使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Chat
的用法示例。
在下文中一共展示了Chat::getChat方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: getSpecific
public function getSpecific()
{
$username = Input::get('username');
$chat = new Chat();
$result = $chat->getChat($username);
return json_encode($result);
}
示例2: checkChat
<?php
require 'classes/chat.class.php';
require 'classes/authenticate.class.php';
require 'login_credentials.php';
global $Chat;
global $Authenticate;
$Chat = new Chat($channel, $twitch, $username);
$Authenticate = new Authenticate($channel);
while (true) {
checkChat($Chat->getChat(), $username, $password, $mod, $color);
sleep(2);
}
function checkChat($message, $username, $password, $mod, $color)
{
global $Chat;
global $Authenticate;
$Login = $Authenticate->Login($username, $password);
$joinChannel = $Authenticate->joinChannel($mod, $color, $Login['remember_me'], $Login['account_token'], $Login['mlg_id'], $Login['mlg_login']);
if (isset($message['Reply'])) {
if ($Authenticate->sendMsg($message['Reply'], $joinChannel['SendData'], $joinChannel['Cookie']) != "OK") {
echo "Message Failed to Send!\n";
}
}
}
示例3: viewChat
public function viewChat()
{
$arrReturn = [];
if (Input::has('chatter_id')) {
$chatterId = Input::get('chatter_id');
if (strlen($chatterId) == 24) {
return Response::json(Chat::getChat($chatterId));
}
}
return $arrReturn;
}