Просмотр файла mobilechat_v1.11color/paikalla.php

Размер файла: 1.29Kb
<?php
header("Content-type: text/vnd.wap.wml; charset=ISO-8859-1");
echo "<?xml version=\"1.0\" encoding=\"ISO-8859-1\" ?>";
echo "<!DOCTYPE wml PUBLIC \"-//WAPFORUM//DTD WML 1.1//EN\"
\"http://www.wapforum.org/DTD/wml_1.1.xml\">\n";
echo "<!-- MobiiliChat v1.1 -->\n";
echo "<!-- Copyright (C) 2004-2005 Keijo Kangas ([email protected]) -->\n";
$salasana=crypt($salasana,'password');
$paikalla=file('chatpaikalla.txt');
$paikzat=count(file('paikalla.txt'));
$hhh=count($paikalla);
echo "<wml>";
echo "<card title=\"Online users\">";
echo "<p>\n";
echo "<small>\n";
echo "<anchor>[Chatroom]";
echo "<go method=\"post\" href=\"chat.php\">";
echo "<postfield name=\"salasana\" value=\"$(salasana)\"/>";
echo "<postfield name=\"nimi\" value=\"$(nimi)\"/>";
echo "</go>";
echo "</anchor><br/>\n";
echo $hhh." users in chatroom:<br/>\n";
for ($i=0; $i<count($paikalla); $i++)
{ 
$a=explode("¤",$paikalla[$i]);
echo rtrim($a[0])."<br/>\n";
}
if (count($paikalla)>5)
{
echo "<anchor>[Chatroom]\n";
echo "<go method=\"post\" href=\"chat.php\">\n";
echo "<postfield name=\"salasana\" value=\"$(salasana)\"/>\n";
echo "<postfield name=\"nimi\" value=\"$(nimi)\"/>\n";
echo "</go>\n";
echo "</anchor><br/>\n";
}

echo "</small>\n";
echo "</p>";
echo "</card>";
echo "</wml>";
?>