<?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";
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";}

print "<card title=\"Fun-ChaT\">
<p align=\"center\">";


if(!empty($login))
$q = @mysql_query("select `id` from `".$px.$utable."` where `login`='".$login."' and ci='$ci';");
if(empty($id)) {

$data = @mysql_fetch_array($q);

$id = $data['id'];
}

$login = autorize();


if($login) {
        if(!$login['ip']) { @mysql_query("update `".$px.$utable."` set `ip`='".getenv(REMOTE_ADDR)."' where `id`='".$id."' and ci='$ci';"); }
        if(!$login['soft']) { @mysql_query("update `".$px.$utable."` set `soft`='".getenv(HTTP_USER_AGENT)."' where `id`='".$id."' and ci='$ci';"); }



if($login['soft']==".getenv(HTTP_USER_AGENT).")        {

print "<small><b>Welcome ".$login['login']."!</b></small><br/>";
print "<small>Your Info Has Been Added To Our Database,Not Spamin in Chat Account Will Be Deleted !<b>".getenv(HTTP_USER_AGENT)."</b></small><br/>";
print "<small>IP: <b>".getenv(REMOTE_ADDR)."</b></small><br/>";
print "<small>Please Enjoy Your Stay Any Help Needed Staff is willing To Assist. :)</small><br/>";
print "<small><a href=\"enter.php?ci=$ci&amp;id=$id&amp;pass=$pass\">&#1042; &#1095;&#1072;&#1090;</a></small><br/>";  }     else
       { @mysql_query("update `".$px.$utable."` set `soft`='".getenv(HTTP_USER_AGENT)."' where `id`='".$id."' and ci='$ci';");

print "<small><b>Welcome ".$login['login']."!</b></small><br/>";
print "<small><b>Here is Your Detail.Plz nt Spamin in chat  Account Will Be Deleted !</b></small><br/>";
print "<small>Browser: <b>".getenv(HTTP_USER_AGENT)."</b></small><br/>";
print "<small>IP: <b>".getenv(REMOTE_ADDR)."</b></small><br/>";
print "<small>Hope You Enjoy Your Stay Here, Any Help Needed Please Contact Moderators or ADMINISTRATOR :)</small><br/>";
print "<small><a href=\"enter.php?ci=$ci&amp;id=$id&amp;pass=$pass\">Enter</a></small><br/>"; }


print "<small>****</small>
<br/><small><a href=\"http://www.2-wap.net\">FunChaT</a></small><br/>";


} else { print "<small><img src=\"image/not.gif\" alt=\"Tty Again\"/><br/><b>Incorect Login Detail</b></small><br/>
<small><a href=\"login.php\">Try Again</a></small>"; }



print "</p>

</card>
</wml>";

@mysql_close();
?>