连接XMPP服务器时出错 [英] Error connecting XMPP server
本文介绍了连接XMPP服务器时出错的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
apache服务器连接时间太长..显示请求超时
apache server is taking too long to connect..showing request timeout
include 'XMPPHP/XMPP.php';
$conn = new XMPPHP_XMPP('talk.google.com', 5222, 'xxx@gmail.com', 'xxxx', 'xmpphp', 'gmail', $printlog=false, $loglevel=XMPPHP_Log::LEVEL_INFO);
try {
$conn->connect();
$conn->processUntil('session_start');
$conn->presence();
$conn->message('foo@example.com', 'This is a test message!');
$conn->disconnect();
} catch(XMPPHP_Exception $e) {
die($e->getMessage());
}
推荐答案
conn = new XMPPHP_XMPP(' talk.google.com',5222, ' xxx@gmail.com',' xxxx',' xmpphp', ' gmail',
conn = new XMPPHP_XMPP('talk.google.com', 5222, 'xxx@gmail.com', 'xxxx', 'xmpphp', 'gmail',
printlog = false,
printlog=false,
loglevel = XMPPHP_Log :: LEVEL_INFO);
尝试 {
loglevel=XMPPHP_Log::LEVEL_INFO); try {
这篇关于连接XMPP服务器时出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文