Hi all
I've had a routine working with PFC 1.2 for the last more than a year. It reads the Nicks of the users in the Chatrooms and displays them on the front page of the forum.
I've recently upgraded to PFC1.3 and now the routine doesn't read the chat users.
PHP version 5.2.17.
Website www.nzmotorhome.co.nz
The code is as follows. Does anyone know why this code would not work when used with 1.3 while it did with 1.2?
<?php
//require './../NZMotorhomeChat/src/pfcinfo.class.php';
require_once 'src/pfcinfo.class.php';
$info = new pfcInfo( md5("ForumChat") );
// NULL is used to get all the connected users, but you can specify
// a channel name to get only the connected user on a specific channel
$users = $info->getOnlineNick(NULL);
echo '<div align="center">';
$info = "";
$number = count($users);
$in_chat = "In Chatroom ";
foreach($users as $name)
{
$comma = ($counter == 0) ? ": " : ", ";
$counter++;
$in_chat = $in_chat . $comma . $name ;
}
$in_chat = ($number != 0) ? $in_chat : "In Chatroom : No one";
echo "</div>";
echo "<div>";
echo "<h3 align=left>".sprintf($in_chat)."</h3>";
echo "</div>";
?>
Any assistance will be greatly appreciated.