ircg_list
(PHP 4 >= 4.3.3, PHP 5 <= 5.0.4)
ircg_list -- チャンネル内のトピック/ユーザの数を取得する
説明
bool
ircg_list ( resource connection, string channel )
ircg_list() は、channel
の中のユーザ数を要求します。結果は、
ircg_set_file() あるいは
ircg_set_current() で定義した出力に返されます。
成功した場合に TRUE を、失敗した場合に FALSE を返します。
例 1. ircg_list() の例 |
<?php
$id = ircg_pconnect($nickname, $ip, $port);
ircg_set_file($id, 'irc_output.html');
if (!ircg_join($id, $channel)) {
echo "Cannot /join $channel<br />";
}
ircg_list($id, $channel);
sleep(5);
ircg_disconnect($id,'Bye World');
readfile('irc_output.html');
?>
|
この例は、以下のような結果を出力します。
...
Channel #channel has n users and the topic is 'Topic'
End of LIST
... |
|
ircg_set_file()、
ircg_set_current() および
ircg_who() も参照ください。
There are no user contributed notes for this page.