<?php

header ("Content-type:text/vnd.wap.wml; charset=utf-8");

print "<?xml version=\"1.0\" encoding=\"utf-8\"?>";
print "<!DOCTYPE wml PUBLIC \"-//WAPFORUM//DTD WML 1.1//EN\"
 \"http://www.wapforum.org/DTD/wml_1.1.xml\">";
print "<wml><head><meta http-equiv=\"Cache-Control\" content=\"no-cache\" forua=\"true\"/></head>";

include "./ini.php";

$login = autorize();
print "<card title=\"Tekwap\">
<p align=\"center\">";
mysql_query ("select * from bannedib WHERE ci='$ci' AND (ip = '".getenv(REMOTE_ADDR)."')and(browser = '".getenv(HTTP_USER_AGENT)."')");
                        if(mysql_affected_rows()!=0){include "b.php";}

$login = autorize();
 {

        $q = @mysql_query("select * from `".$px.$utable."` where id='".$whoid."' and ci='".$ci."';");

        $dbuser = @mysql_fetch_array($q);

        switch($mod) {

 

        case 'comments':
        if(empty($act)) {
        print "User:<br/><input name=\"who\" value=\"$who\"/><br/>
        Status:<br/><input name=\"Comments\" value=\"".$data['Comments']."\"/><br/>
        <anchor>Add Comments<go href=\"./comments.php?ci=$ci&amp;id=$id&amp;pass=$pass&amp;mod=$mod\" method=\"post\">
        <postfield name=\"act\" value=\"set\"/>
        <postfield name=\"who\" value=\"$(who)\"/>
	
        <postfield name=\"Comments\" value=\"$(Comments)\"/>
        </go></anchor><br/>"; } else {

        if(@mysql_query("update `".$px.$utable."` set Comments='$Comments' where login='$who' and ci='$ci'")) {print "C&#1090;&#1072;&#1090;&#1091;&#1089; &#1080;&#1079;&#1084;&#1077;&#1085;&#1077;&#1085;";}

        }
        break;

    

        default:
        print "<small><a href=\"comments.php?ci=$ci&amp;id=$id&amp;pass=$pass&amp;mod=comments\">Add Comments</a></small><br/>";
         
        break;
        }

        if($mod) {
        print "<anchor>Previous Page<prev/></anchor><br/>";
        print "<a href=\"comments.php?ci=$ci&amp;id=$id&amp;pass=$pass\">Administrator</a><br/>";
        }
        if($room)
        print "<a href=\"./room.php?ci=$ci&amp;id=$id&amp;pass=$pass&amp;room=$room\">Back</a><br/>";
        else
        print "<small><a href=\"./enter.php?ci=$ci&amp;id=$id&amp;pass=$pass\">Hall</a></small><br/>";
        } 
@mysql_close();
print "</p>
</card>
</wml>";
ob_end_flush();
?>