View file wap/ownrproc.php

File size: 67.56Kb
<?php
include("inc/func.inc.php");
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
header("Cache-Control: no-cache, must-revalidate");
header("Pragma: no-cache");
echo "<?xml version=\"1.0\"?>\n";
echo "<!DOCTYPE html PUBLIC \"-//WAPFORUM//DTD XHTML Mobile 1.0//EN\" \"http://www.wapforum.org/DTD/xhtml-mobile10.dtd\">\n";
?>
<html xmlns="http://www.w3.org/1999/xhtml">
<?php
  if(!db()){
  echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
  echo "</head>";
  echo "<body>";
  echo getdberror();
  echo "</body>";
  echo "</html>";
  exit();
  }

  $show = $_GET["show"];
  $hits = $_GET["hits"];
  $page = $_GET["page"];
  $who = $_GET["who"];
  $uid = getuid_hits($hits);
  $uip = getip();
  $ubr = $_SERVER['HTTP_USER_AGENT'];
  cleardata();
  addvisitor();

  if(isipbanned($uip,$ubr)){
  if(!isshield(getuid_hits($hits))){
  echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
  echo "</head>";
  echo "<body>";
  echo getipbanned($uip, $ubr);
  echo "</body>";
  echo "</html>";
  exit();
  }
  }

  if(($show != "") && ($show != "terms")){
  $uid = getuid_hits($hits);
  if((islogged($hits)==false)||($uid==0)){
  echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
  echo "</head>";
  echo "<body>";
  echo getsesexplog();
  echo "</body>";
  echo "</html>";
  exit();
  }
  }

  if((isbanned($uid))&&($uid != '0')){
  echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
  echo "</head>";
  echo "<body>";
  echo getbanned($uid);
  echo "</body>";
  echo "</html>";
  exit();
  }

 if(!isowner(getuid_hits($hits)))
  {
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
      echo getpagerror();
      echo "</body>";
      echo "</html>";
      exit();
    }

    if(!isonlinecp(getuid_hits($hits)))
    {
      echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  echo getstafflog($hits);
  echo "</body>";
  echo "</html>";
  exit();
    }

addonline(getuid_hits($hits),"Founder CP","");

//////////////////////////general settings//////////////////////////

if($show=="general")
{
  $xtm = $_POST["sesp"];
  $shoutbox = $_POST["shoutbox"];
  $areg = $_POST["areg"];
  $vldtn = $_POST["vldtn"];
  $pmaf = $_POST["pmaf"];
  $fvw = $_POST["fvw"];
  if($areg=="d")
  {
  $arv = 0;
  }else{
  $arv = 1;
  }
  if($vldtn=="d")
  {
  $valid = 0;
  }else{
  $valid = 1;
  }
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";  
  $res = mysql_query("UPDATE mx_settings SET value='".$shoutbox."' WHERE name='shoutbox'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Site Name updated successfully<br/>";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating Site Name<br/>";
  }
  $res = mysql_query("UPDATE mx_settings SET value='".$xtm."' WHERE name='sesxp'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Session Period updated successfully<br/>";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating Session Period<br/>";
  }
  $res = mysql_query("UPDATE mx_settings SET value='".$pmaf."' WHERE name='pmaf'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>PM antiflood is $pmaf seconds<br/>";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating PM antiflood value<br/>";
  }
  $res = mysql_query("UPDATE mx_settings SET value='".$arv."' WHERE name='reg'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Registration updated successfully<br/>";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating Registration<br/>";
  }
  $res = mysql_query("UPDATE mx_settings SET value='".$fvw."' WHERE name='fview'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Forums View updated successfully<br/>";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating Forums View<br/>";
  }
  $res = mysql_query("UPDATE mx_settings SET value='".$valid."' WHERE name='vldtn'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Validation updated successfully<br/>";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating Validation<br/>";
  }
  echo "<br/>";
  echo "<a href=\"ownercp.php?show=general&amp;hits=$hits\">Edit general settings</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
else if($show=="recomp")
{
  $type = $_GET["type"];
           echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"MaxHits.CO.CC\">";
      echo "<p align=\"center\">";
 if($type=='1')
 {
	  $res = mysql_query("UPDATE mx_users SET upload='0'");
 }else if($type=='2')
 {
	  $res = mysql_query("UPDATE mx_users SET tottimeonl2='0'");
 }else if($type=='3')
 {
	  $res = mysql_query("UPDATE mx_users SET posts2='0'");
 }else if($type=='4')
 {
	  $res = mysql_query("UPDATE mx_users SET chmsgs2='0'");
 }else if($type=='5')
 {
	  $res = mysql_query("UPDATE mx_users SET shouts2='0'");
 }else if($type=='6')
 {
	  $res = mysql_query("UPDATE mx_users SET blog='0'");
 }else if($type=='7')
 {
	  $res = mysql_query("UPDATE mx_users SET lyric='0'");
  }
      if($res)
      {
        echo "<img src=\"images/ok.gif\" alt=\"O\"/>Selected Competition Has Been Restart Successfully!<br/>";
      }else{
        echo "<img src=\"images/notok.gif\" alt=\"X\"/>Syntax Error<br/>";
      }
      
      echo "<br/><br/><a href=\"index.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"*\"/>";
  echo "Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
  echo "Home</a>";
  echo "</p></body>";
}
//////////////////////////////////////Invisible

else if($show=="visible")
{
  $who = $_GET["who"];
  $visible = $_POST["visible"];
           echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"lavalair.net\">";
      echo "<p align=\"center\">";

	  $res = mysql_query("UPDATE mx_users SET visible='".$visible."' WHERE id='".$who."'");
      if($res)
      {
        echo "<img src=\"images/ok.gif\" alt=\"O\"/>Invisible Mode Updated Successfully<br/>";
        mysql_query("DELETE FROM mx_ses WHERE uid='".$who."'");
        mysql_query("DELETE FROM mx_online WHERE userid='".$who."'");
      }else{
        echo "<img src=\"images/notok.gif\" alt=\"X\"/>Invisible Mode Error<br/>";
      }
      
      echo "<br/><br/><a href=\"index.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"*\"/>";
  echo "Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
  echo "Home</a>";
  echo "</p></body>";
}
else if($show=="delpms2")
{
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $altm = time()-(5*24*60*60);
  echo "<br/>";
  $res = mysql_query("DELETE FROM mx_private WHERE starred='0' AND timesent<'".$altm."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>All inboxes except starred were deleted";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error!";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=clrdta&amp;hits=$hits\">Clear Data</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
else if($show=="delw")
{
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $altm = time()-(7*24*60*60);
  $id = mysql_fetch_array(mysql_query("SELECT id FROM status WHERE sent<'".$altm."'"));

  $res = mysql_query("DELETE FROM statuscomment WHERE refid='".$id[0]."'");
  $res = mysql_query("DELETE FROM status WHERE sent<'".$altm."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Old wall post clear successful";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error!";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=clrdta&amp;hits=$hits\">Clear Data</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
else if($show=="dellv")
{
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder Tools\">";
  echo "<p align=\"center\">";
  $altm = time()-(4*24*60*60);
  echo "<br/>";
  $res = mysql_query("DELETE FROM mx_proviews WHERE date<'".$altm."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Last View Older Than 5 days were deleted";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error!";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=clrdta&amp;hits=$hits\">Clear Data</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder Tools</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
else if($show=="delpops")
{
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder Tools\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $res = mysql_query("DELETE FROM mx_popups WHERE reported!='1' AND unread='0'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>All popups except reported, and unread were deleted";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error!";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=clrdta&amp;hits=$hits\">Clear Data</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder Tools</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////////////////////shout

else if($show=="oshout")
{
  $shtxt = $_POST["shtxt"];
    addonline(getuid_hits($hits),"Adding Site Info","");

            echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Site Info\">";
    echo "<p align=\"center\">";
      $shtxt = $shtxt;
    $uid = getuid_hits($hits);
    $shtm = time();
    $res = mysql_query("INSERT INTO mx_oshouts SET shout='".$shtxt."', shouter='".$uid."', shtime='".$shtm."'");
    if($res)
    {
    echo "<img src=\"images/ok.gif\" alt=\"O\"/>Site Info added successfully";
    }else{
        echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error";
    }
         echo "<br/><br/><a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
echo "Home</a>";
    echo "</p>";
    echo "</body>";
}


else if($show=="validate")
{
  $who = $_GET["who"];
  $user = getnick_uid($who);
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $res = mysql_query("Update mx_users SET validated='1' WHERE id='".$who."'");
  if($res)
  {
  $sub = "Account Validate ! !";
  $nama = getnick_uid($who);
  $shtxt = "Hai $nama, Your Account Has Been Validate ! ! Now You Can Use All Service In This Wap. Thank You Because Join This Wap Site. Feel Free To Invite Your Friends Join Here ! .pis.";
    mysql_query("INSERT INTO mx_private SET text='".$shtxt."', byuid='1', touid='".$who."', sub='".$sub."', timesent='".time()."'");
  mysql_query("INSERT INTO mx_mlog SET action='validation', details='<b>".getnick_uid(getuid_hits($hits))."</b> validated $user', actdt='".time()."'");
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>$user validated successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error validating $user";
  }
  echo "<br/><br/><a href=\"prov.php?show=viewuser&amp;who=$who&amp;hits=$hits\">$user's Profile</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p>";
  echo "</body>";
}
//////////////////////////boot user//////////////////////////

else if($show=="boot")
{
  $who = $_GET["who"];
  $user = getnick_uid($who);
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $uid = getuid_hits($hits);
  $res = mysql_query("DELETE FROM mx_ses WHERE uid='".$who."'");
  if($res)
  {
  mysql_query("INSERT INTO mx_mlog SET action='boot', details='<b>".getnick_uid(getuid_hits($hits))."</b> booted $user', actdt='".time()."'");
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>$user Kicked successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Kicking $user";
  }
  echo "<br/><br/><a href=\"prov.php?show=viewuser&amp;who=$who&amp;hits=$hits\">$user's Profile</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p>";
  echo "</body>";
}
else if($show=="pun")
{
    $pid = $_POST["pid"];
    $who = $_GET["who"];
    $pres = $_POST["pres"];
    $pds = $_POST["pds"];
    $phr = $_POST["phr"];
    $pmn = $_POST["pmn"];
    $psc = $_POST["psc"];
            echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Owner CP\">";

  echo "<p align=\"center\">";

  $uip = "";
  $ubr = "";
  $pmsg[0]="Mute";
  $pmsg[1]="Banned";
  $pmsg[2]="IP-Banned";
  if($pid=='2')
  {
    //ip ban
    $uip = getip_uid($who);
    $ubr = getbr_uid($who);
  }
  if(trim($pres)=="")
  {
    echo "<img src=\"images/notok.gif\" alt=\"X\"/>You must Specify A Reson For Punishing The User";
  }else{
    $timeto = $pds*24*60*60;
    $timeto += $phr*60*60;
    $timeto += $pmn*60;
    $timeto += $psc;
    $ptime = $timeto + time();
    $unick = getnick_uid($who);

    $res = mysql_query("INSERT INTO mx_penalties SET uid='".$who."', penalty='".$pid."', exid='".getuid_hits($hits)."', timeto='".$ptime."', pnreas='".mysql_escape_string($pres)."', ipadd='".$uip."', browserm='".$ubr."'");

    if($res)
          {
            mysql_query("UPDATE mx_users SET  lastpnreas='".$pmsg[$pid].": ".mysql_escape_string($pres)."' WHERE id='".$who."'");
            mysql_query("INSERT INTO mx_mlog SET action='penalties', details='<b>".getnick_uid(getuid_hits($hits))."</b> $pmsg[$pid] The user <b>".$unick."</b> For ".$timeto." Seconds', actdt='".time()."'");
            
            echo "<img src=\"images/ok.gif\" alt=\"O\"/>$unick is $pmsg[$pid] for $timeto Seconds";
          }else{
            echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error";
          }
  }
    echo "<br/><br/><a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
echo "Home</a>";
include("wapv.php");
  echo "</p></body>";
}
else if($show=="delchr")
{
  $chrid = $_POST["chrid"];
            echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"MaxHits.CO.CC\">";
      echo "<p align=\"center\">";
        echo "<br/>";
        $res = mysql_query("DELETE FROM mx_rooms WHERE id='".$chrid."'");

        if($res)
      {
        echo "<img src=\"images/ok.gif\" alt=\"O\"/>Room  deleted successfully";
      }else{
        echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error";
      }

      echo "<br/><br/><a href=\"ownercp.php?show=chrooms&amp;hits=$hits\">";
  echo "Chatrooms</a><br/>";
      echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"*\"/>";
  echo "Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
  echo "Home</a>";
include("wapv.php");

      echo "</p></body>";
}
else if($show=="addchr")
{
  $chrnm = $_POST["chrnm"];
  $chrage = $_POST["chrage"];
  $chrpst = $_POST["chrpst"];
  $chrprm = $_POST["chrprm"];
  $chrcns = $_POST["chrcns"];
  $chrfun = $_POST["chrfun"];
  
  

            echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"MaxHits.CO.CC\">";
      echo "<p align=\"center\">";
        echo $chrnm;
        echo "<br/>";
        $res = mysql_query("INSERT INTO mx_rooms SET name='".$chrnm."', static='1', pass='', mage='".$chrage."', chposts='".$chrpst."', perms='".$chrprm."', censord='".$chrcns."' , freaky='".$chrfun."'");
echo mysql_error();
        if($res)
      {
        echo "<img src=\"images/ok.gif\" alt=\"O\"/>Chatroom added successfully";
      }else{
        echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error adding Chat room";
      }

      echo "<br/><br/><a href=\"ownercp.php?show=chrooms&amp;hits=$hits\">";
  echo "Chatrooms</a><br/>";
      echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"*\"/>";
  echo "Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
  echo "Home</a>";
include("wapv.php");

      echo "</p></body>";
}

//////////////////////////shield user//////////////////////////

else if($show=="shld")
{
  $who = $_GET["who"];
  $user = getnick_uid($who);
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $res = mysql_query("Update mx_users SET shield='1' WHERE id='".$who."'");
  if($res)
  {
  $unick = getnick_uid($who);
  mysql_query("INSERT INTO mx_mlog SET action='penalties', details='<b>".getnick_uid(getuid_hits($hits))."</b> Shielded The user <b>".$unick."</b>', actdt='".time()."'");
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>$unick is Shielded";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error";
  }
  echo "<br/><br/><a href=\"prov.php?show=viewuser&amp;who=$who&amp;hits=$hits\">$user's Profile</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////unshield user//////////////////////////

else if($show=="ushld")
{
  $who = $_GET["who"];
  $user = getnick_uid($who);
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $res = mysql_query("Update mx_users SET shield='0' WHERE id='".$who."'");
  if($res)
  {
  $unick = getnick_uid($who);
  mysql_query("INSERT INTO mx_mlog SET action='penalties', details='<b>".getnick_uid(getuid_hits($hits))."</b> Unshielded The user <b>".$unick."</b>', actdt='".time()."'");
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>$unick is Unshielded";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error";
  }
  echo "<br/><br/><a href=\"prov.php?show=viewuser&amp;who=$who&amp;hits=$hits\">$user's Profile</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////untrash user//////////////////////////

else if($show=="untr")
{
  $who = $_GET["who"];
  $user = getnick_uid($who);
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $res = mysql_query("DELETE FROM mx_penalties WHERE penalty='0' AND uid='".$who."'");
  if($res)
  {
  $unick = getnick_uid($who);
  mysql_query("INSERT INTO mx_mlog SET action='unmute', details='<b>".getnick_uid(getuid_hits($hits))."</b> Unmute The user <b>".$unick."', actdt='".time()."'");
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>$unick Unmute";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error";
  }
  echo "<br/><br/><a href=\"prov.php?show=viewuser&amp;who=$who&amp;hits=$hits\">$user's Profile</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}

//////////////////////////unban user//////////////////////////

else if($show=="unbn")
{
  $who = $_GET["who"];
  $user = getnick_uid($who);
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $res = mysql_query("DELETE FROM mx_penalties WHERE (penalty='1' OR penalty='2') AND uid='".$who."'");
  if($res)
  {
  $unick = getnick_uid($who);
  mysql_query("INSERT INTO mx_mlog SET action='unbanned', details='<b>".getnick_uid(getuid_hits($hits))."</b> Unbanned The user <b>".$unick."</b>', actdt='".time()."'");
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>$unick Unbanned";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error";
  }
  echo "<br/><br/><a href=\"prov.php?show=viewuser&amp;who=$who&amp;hits=$hits\">$user's Profile</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////delete user//////////////////////////

else if($show=="delu")
{
  $who = $_GET["who"];
  $user = getnick_uid($who);
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $uid = getuid_hits($hits);
  $perm = mysql_fetch_array(mysql_query("SELECT spermis FROM mx_users WHERE id='".$uid."'"));
  $trgtperm = mysql_fetch_array(mysql_query("SELECT spermis FROM mx_users WHERE name='".$user."'"));

  if($trgtperm>$perm){ 
  echo "<b><img src=\"images/notok.gif\" alt=\"x\"/><br/>Error!!!<br/>Permission Denied...</b><br/>";
  echo "<br/>U Cannot Delete $user<br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p>";
  }else{

  echo "<br/>";
  $res = mysql_query("DELETE FROM mx_buddies WHERE tid='".$who."' OR uid='".$who."'");
  $res = mysql_query("DELETE FROM mx_gbook WHERE gbowner='".$who."' OR gbsigner='".$who."'");
  $res = mysql_query("DELETE FROM mx_ignore WHERE name='".$who."' OR target='".$who."'");
  $res = mysql_query("DELETE FROM mx_mangr WHERE uid='".$who."'");
  $res = mysql_query("DELETE FROM mx_modr WHERE name='".$who."'");
  $res = mysql_query("DELETE FROM mx_penalties WHERE uid='".$who."' OR exid='".$who."'");
  $res = mysql_query("DELETE FROM mx_posts WHERE uid='".$who."'");
  $res = mysql_query("DELETE FROM mx_private WHERE byuid='".$who."' OR touid='".$who."'");
  $res = mysql_query("DELETE FROM mx_popups WHERE byuid='".$who."' OR touid='".$who."'");
  $res = mysql_query("DELETE FROM mx_shouts WHERE shouter='".$who."'");
  $res = mysql_query("DELETE FROM mx_topics WHERE authorid='".$who."'");
  $res = mysql_query("DELETE FROM mx_brate WHERE uid='".$who."'");
  $res = mysql_query("DELETE FROM mx_games WHERE uid='".$who."'");
  $res = mysql_query("DELETE FROM mx_presults WHERE uid='".$who."'");
  $res = mysql_query("DELETE FROM mx_vault WHERE uid='".$who."'");
  $res = mysql_query("DELETE FROM mx_blogs WHERE bowner='".$who."'");
  $res = mysql_query("DELETE FROM mx_chat WHERE chatter='".$who."'");
  $res = mysql_query("DELETE FROM mx_chat WHERE who='".$who."'");
  $res = mysql_query("DELETE FROM mx_chonline WHERE uid='".$who."'");
  $res = mysql_query("DELETE FROM mx_online WHERE userid='".$who."'");
  $res = mysql_query("DELETE FROM mx_ses WHERE uid='".$who."'");
  $res = mysql_query("DELETE FROM mx_xinfo WHERE uid='".$who."'");
  deleteMClubs($who);
  $res = mysql_query("DELETE FROM mx_users WHERE id='".$who."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>User  deleted successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error deleting UGroup";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=chuinfo&amp;hits=$hits\">User info</a><br/>";
  echo "<br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  }
  echo "</p></body>";
}
//////////////////////////plusses//////////////////////////

else if($show=="pls")
{
  $pid = $_POST["pid"];
  $who = $_GET["who"];
  $pres = $_POST["pres"];
  $pval = $_POST["pval"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $unick = getnick_uid($who);
  $opl = mysql_fetch_array(mysql_query("SELECT plusses FROM mx_users WHERE id='".$who."'"));
  if($pid=='0')
  {
  $npl = $opl[0] - $pval;
  }else{
  $npl = $opl[0] + $pval;
  }
  if($npl<0)
  {
  $npl=0;
  }
  if(trim($pres)=="")
  {
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>You must Specify a reson for updating $unick's Plusses";
  }else{
  $res = mysql_query("UPDATE mx_users SET lastplreas='".mysql_escape_string($pres)."', plusses='".$npl."' WHERE id='".$who."'");
  if($res)
  {
  mysql_query("INSERT INTO mx_mlog SET action='plusses', details='<b>".getnick_uid(getuid_hits($hits))."</b> Updated <b>".$unick."</b> plusses from ".$opl[0]." to $npl', actdt='".time()."'");
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>$unick's Plusses Updated From $opl[0] to $npl";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error";
  }
  }
  echo "<br/><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////clear reports/logs//////////////////////////

else if($show=="clrmlog")
{
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $res = mysql_query("DELETE FROM mx_mlog");
  echo mysql_error();
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>ModLog Cleared Successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error!";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=clrdta&amp;hits=$hits\">Clear Data</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////clear reports/logs//////////////////////////

else if($show=="delhall")
{
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $id = $_GET["id"];
  $res = mysql_query("DELETE FROM mx_halloffame WHERE id='".$id."'");
  echo mysql_error();
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Hall Of Fame Delete Successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error!";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
 include("wapv.php");
  echo "</p></body>";
}

else if($show=="addhall")
{
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $who = $_GET["who"];
  $title = $_POST["title"];
  $status = $_POST["status"];
  $name = getnick_uid($who);
      $crdate = time();
  $res = mysql_query("INSERT INTO mx_halloffame SET who='".$who."', name='".$name."', title='".$title."', status='".$status."', date='".$crdate."'");
  echo mysql_error();
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Hall Of Fame Add Successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error!";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
 include("wapv.php");
  echo "</p></body>";
}
//////////////////////////clear inboxs//////////////////////////

else if($show=="delpms")
{
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $res = mysql_query("DELETE FROM mx_private WHERE reported!='1' AND starred='0' AND unread='0'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>All inboxes except starred, reported, and unread were deleted";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error!";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=clrdta&amp;hits=$hits\">Clear Data</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////clear popups//////////////////////////

else if($show=="delpops")
{
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $res = mysql_query("DELETE FROM mx_popups WHERE reported!='1' AND unread='0'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>All popups except reported, and unread were deleted";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error!";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=clrdta&amp;hits=$hits\">Clear Data</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////clear shouts//////////////////////////

else if($show=="delsht")
{
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $res = mysql_query("DELETE FROM mx_shouts");
  if($res)
  {
    $status = getstatus($uid);
    $uid = getuid_hits($hits);
    $nick = getnick_uid($uid);
    $shtxt = "Last Shouts Has Been Clear By $status $nick!! Thank You.";
    $shtm = time();

    mysql_query("INSERT INTO mx_shouts SET shout='".$shtxt."', shouter='1', shtime='".$shtm."'");
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Old Shouts Deleted";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error!";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=clrdta&amp;hits=$hits\">Clear Data</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////add blocked site//////////////////////////

else if($show=="addsite")
{
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $site = $_POST["site"];
  echo $site;
  $res = mysql_query("INSERT INTO mx_blockedsite SET site='".$site."'");
  if($res)
  {
  echo mysql_error();
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Site $site Added Successfully to Blocked List<br/>";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Adding Site<br/>";
  }
  echo "<br/>";
  echo "<a href=\"ownercp.php?show=blocksites&amp;hits=$hits\">Blocked Sites List</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
  }
//////////////////////////delete blocked site//////////////////////////

else if($show=="delsite")
{
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $id=$_GET["id"];
  $sitena = mysql_query("SELECT site FROM mx_blockedsite WHERE id='".$id."'");
  $site = mysql_fetch_array($sitena);
  $site=$site[0];
  $res = mysql_query("DELETE FROM mx_blockedsite WHERE id='".$id."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Site $site Removed Successfully from Blocked List<br/>";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Removing $site <br/>";
  }
  echo "<br/>";
  echo "<a href=\"ownercp.php?show=blocksites&amp;hits=$hits\">Blocked Sites List</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////add forum moderator//////////////////////////

else if($show=="addfmod")
{
  $mid = $_POST["mid"];
  $fid = $_POST["fid"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $res = mysql_query("INSERT INTO mx_modr SET name='".$mid."', forum='".$fid."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Moding Privileges Added<br/>";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error<br/>";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=manmods&amp;hits=$hits\">Manage Moderators</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////delete forum moderator//////////////////////////

else if($show=="delfmod")
{
  $mid = $_POST["mid"];
  $fid = $_POST["fid"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $res = mysql_query("DELETE FROM mx_modr WHERE name='".$mid."' AND forum='".$fid."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Moding Privileges Deleted<br/>";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error<br/>";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=manmods&amp;hits=$hits\">Manage Moderators</a><br/>";
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////add smilie//////////////////////////

else if($show=="addsml")
{
  $smlcde = $_POST["smlcde"];
  $smlsrc = $_POST["smlsrc"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $res = mysql_query("INSERT INTO mx_smilies SET scode='".$smlcde."', imgsrc='".$smlsrc."', hidden='0'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Smilie  added successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error adding Smilie ";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=addsml&amp;hits=$hits\">Add Another Smilie</a><br/>";
  echo "<br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////delete smilie//////////////////////////

else if($show=="delsm")
{
  $smid = $_GET["smid"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $res = mysql_query("DELETE FROM mx_smilies WHERE id='".$smid."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Smilie  deleted successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error deleting smilie ";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////add avartar//////////////////////////

else if($show=="addavt")
{
  $avtsrc = $_POST["avtsrc"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "Source: ".$avtsrc;
  echo "<br/>";
  $res = mysql_query("INSERT INTO mx_avatars SET avlink='".$avtsrc."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Avatar  added successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error adding Avatar ";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=addavt&amp;hits=$hits\">Add Another Avatar</a><br/>";
  echo "<br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
/////////////////////////////RemiXchaT///////////////////////

else if($show=="adduicon")
{
  $avtsrc = $_POST["avtsrc"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "Source: ".$avtsrc;
  echo "<br/>";
  $res = mysql_query("INSERT INTO mx_uicons SET avlink='".$avtsrc."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Nick Icon added successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error adding Nick Icon";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=adduicon&amp;hits=$hits\">Add Another Nick Icon</a><br/>";
  echo "<br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////add judge//////////////////////////

else if($show=="addjdg")
{
  $who = $_GET["who"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $res = mysql_query("INSERT INTO mx_judges SET uid='".$who."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Judge  added successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error adding Judge ";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=chuinfo&amp;hits=$hits\">Users Info</a><br/>";
  echo "<br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////remove judge//////////////////////////

else if($show=="deljdg")
{
  $who = $_GET["who"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $res = mysql_query("DELETE FROM mx_judges WHERE uid='".$who."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Judge  deleted successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error deleting Judge ";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=chuinfo&amp;hits=$hits\">Users Info</a><br/>";
  echo "<br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////add rss//////////////////////////

else if($show=="addrss")
{
  $rssnm = $_POST["rssnm"];
  $rsslnk = $_POST["rsslnk"];
  $type = $_POST["type"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo $rssnm;
  echo "<br/>";
  $res = mysql_query("INSERT INTO mx_rss SET title='".$rssnm."', link='".$rsslnk."', fid='0', type='".$type."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Source added successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error adding RSS Source";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=manrss&amp;hits=$hits\">Manage RSS</a><br/>";
  echo "<br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////edit rss//////////////////////////

else if($show=="edtrss")
{
  $rssnm = $_POST["rssnm"];
  $rsslnk = $_POST["rsslnk"];
  $type = $_POST["type"];
  $rshits = $_POST["rshits"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo $rssnm;
  echo "<br/>";
  $res = mysql_query("UPDATE mx_rss SET title='".$rssnm."', link='".$rsslnk."', type='".$type."' WHERE id='".$rshits."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Source updated successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error updating RSS Source";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=manrss&amp;hits=$hits\">Manage RSS</a><br/>";
  echo "<br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////delete rss//////////////////////////

else if($show=="delrss")
{
  $rshits = $_POST["rshits"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $res = mysql_query("DELETE FROM mx_rss WHERE id='".$rshits."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Source  deleted successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=manrss&amp;hits=$hits\">Manage RSS</a><br/>";
  echo "<br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////add permission//////////////////////////

else if($show=="addperm")
{
  $fid = $_POST["fid"];
  $gid = $_POST["gid"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $res = mysql_query("INSERT INTO mx_acc SET fid='".$fid."', gid='".$gid."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Permission  added successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error adding permission ";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=addperm&amp;hits=$hits\">Add Permission</a><br/>";
  echo "<a href=\"index.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
else if($show=="addhall")
{
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $who = $_GET["who"];
  $title = $_POST["title"];
  $status = $_POST["status"];
  $name = getnick_uid($who);
  $res = mysql_query("INSERT INTO mx_halloffame SET id='".$who."', name='".$name."', title='".$title."', status='".$status."'");
  echo mysql_error();
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>Hall Of Fame Add Successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error!";
  }
  echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////edit profile//////////////////////////

else if($show=="uprof")
{
  $who = $_GET["who"];
  $unick = $_POST["unick"];
  $perm = $_POST["perm"];
  $zerm = $_POST["zerm"];
  $semail = $_POST["semail"];
  $ubday = $_POST["ubday"];
  $uloc = $_POST["uloc"];
  $usig = $_POST["usig"];
  $usex = $_POST["usex"];
  $user = getnick_uid($who);
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $onk = mysql_fetch_array(mysql_query("SELECT name FROM mx_users WHERE id='".$who."'"));
  $exs = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM mx_users WHERE name='".$unick."'"));
  if($onk[0]!=$unick)
  {
  if($exs[0]>0)
  {
  echo "<img src=\"images/notok.gif\" alt=\"x\"/>New nickname already exist, choose another one<br/>";
  }else{

 if($perm=="0")
 {
  $res = mysql_query("UPDATE mx_users SET email='".$semail."', birthday='".$ubday."', location='".$uloc."', signature='".$usig."', sex='".$usex."', name='".$unick."', spermis='".$perm."', zerm='".$zerm."' WHERE id='".$who."'");

 }else{

 $len = 7;
 $chars = 'abadefghijklmnopqrstuvwxyz0123456789';
 $hug = '';
 for ($i = 0; $i < $len; $i++) {
 $pos = rand(0, strlen($chars)-1);
 $hug .= $chars{$pos};
  }

  $cpwd = md5($hug);

  $res = mysql_query("UPDATE mx_users SET email='".$semail."', birthday='".$ubday."', location='".$uloc."', signature='".$usig."', sex='".$usex."', name='".$unick."', spermis='".$perm."', zerm='".$zerm."', passcp='".$cpwd."' WHERE id='".$who."'");
 }

  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"o\"/>$unick's profile was updated successfully<br/>";
 if($perm != '0')
 {

  $sub = "Congratulation.";
  $msg = "Hai, Now You Is RemiXchaT.CoM Crew. Tool Password: ".$hug." Please Remember And Don't Share To Any One This Password Or You Will Be Drop From Crew Lists.";
 $msg = mysql_escape_string($msg);
   $who = $_GET["who"];
   autopm($msg, $who, $sub);

 }
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"x\"/>Error updating $unick's profile<br/>";
  }
  }

  }else{

 if($perm=="0")
 {
  $res = mysql_query("UPDATE mx_users SET email='".$semail."', birthday='".$ubday."', location='".$uloc."', signature='".$usig."', sex='".$usex."', name='".$unick."', spermis='".$perm."', zerm='".$zerm."' WHERE id='".$who."'");

 }else{

 $len = 7;
 $chars = 'abadefghijklmnopqrstuvwxyz0123456789';
 $hug = '';
 for ($i = 0; $i < $len; $i++) {
 $pos = rand(0, strlen($chars)-1);
 $hug .= $chars{$pos};
  }
 $cpwd = md5($hug);

  $res = mysql_query("UPDATE mx_users SET email='".$semail."', birthday='".$ubday."', location='".$uloc."', signature='".$usig."', sex='".$usex."', name='".$unick."', spermis='".$perm."', zerm='".$zerm."', passcp='".$cpwd."' WHERE id='".$who."'");
 }
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"o\"/>$unick's profile was updated successfully<br/>";

  if($perm != '0')
 {

  $sub = "Congratulation.";
  $msg = "Hai, Now You Is RemiXchaT.CoM Crew. Tool Password: ".$hug." Please Remember And Don't Share To Any One This Password Or You Will Be Drop From Crew Lists.";
 $msg = mysql_escape_string($msg);
   $who = $_GET["who"];
   autopm($msg, $who, $sub);

 }

  }else{
  echo "<img src=\"images/notok.gif\" alt=\"x\"/>Error updating $unick's profile<br/>";
  }

  }
  echo "<br/><a href=\"ownercp.php?show=chuinfo&amp;hits=$hits\">Users Info</a><br/>";
  echo "<br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////reset password//////////////////////////

else if($show=="upwd")
{
  $npwd = $_POST["npwd"];
  $who = $_GET["who"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
    if((strlen($npwd)<4) || (strlen($npwd)>15)){
  echo "<img src=\"images/notok.gif\" alt=\"x\"/>password should be between 4 and 15 letters only<br/>";
  }else{
  $pwd = md5($npwd);
  $res = mysql_query("UPDATE mx_users SET pass='".$pwd."' WHERE id='".$who."'");
  if($res)
  {
  echo "<img src=\"images/ok.gif\" alt=\"o\"/>password was updated successfully<br/>";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"x\"/>Error updating password<br/>";
  }
  }
  echo "<br/><a href=\"ownercp.php?show=chuinfo&amp;hits=$hits\">Users Info</a><br/>";
  echo "<br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
//////////////////////////Delete users posts//////////////////////////

else if($show=="delxp")
{
  $who = $_GET["who"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  echo "<br/>";
  $res = mysql_query("DELETE FROM mx_posts WHERE uid='".$who."'");
  $res = mysql_query("DELETE FROM mx_topics WHERE authorid='".$who."'");
  if($res)
  {
  mysql_query("UPDATE mx_users SET plusses='0' where id='".$who."'");
  echo "<img src=\"images/ok.gif\" alt=\"O\"/>User Posts deleted successfully";
  }else{
  echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error deleting UPosts";
  }
  echo "<br/><br/><a href=\"ownercp.php?show=chuinfo&amp;hits=$hits\">User info</a><br/>";
  echo "<br/><a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"\"/>Founder CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
  echo "</p></body>";
}
 else if($show=="onall2")
{
 $limit = $_POST["limit"];
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Online All\">";
  echo "<p align=\"center\">";
 if(isowner(getuid_hits($hits)))
{
  $pms = mysql_query("SELECT id, name FROM mx_users WHERE spermis='0' ORDER BY RAND()  LIMIT $limit");

  while($pm=mysql_fetch_array($pms))
  {

  mysql_query("UPDATE mx_users SET lastact='".time()."' WHERE id='".$pm[0]."'");

$num1 = rand(1, 9);
if($num1=='1')
{
$lala = "Main Menu";
}if($num1=='2')
{
$lala = "Shout Box";
}if($num1=='3')
{
$lala = "Lyric Menu";
}if($num1=='4')
{
$lala = "Buddies List";
}if($num1=='5')
{
$lala = "Inbox Menu";
}if($num1=='6')
{
$lala = "Main Forum";
}if($num1=='7')
{
$lala = "All Online List";
}if($num1=='8')
{
$lala = "F.A.Q Menu";
}if($num1=='9')
{
$lala = "Viewing Users Profile";
}

  mysql_query("INSERT INTO mx_online SET userid='".$pm[0]."', actvtime='".time()."', place='".$lala."'");

  }
 echo "Done!!<br/><br/>";
 }else{
 echo "You Can Do That!!<br/><br/>";
 }
 echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
echo "Home</a>";
include("wapv.php");

  echo "</p>";
    echo "</body>";
}
 else if($show=="onall")
{
          echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Online All\">";
  echo "<p align=\"center\">";
 if(isowner(getuid_hits($hits)))
{
  $pms = mysql_query("SELECT id, name FROM mx_users WHERE spermis='0'");

  while($pm=mysql_fetch_array($pms))
  {

  mysql_query("UPDATE mx_users SET lastact='".time()."' WHERE id='".$pm[0]."'");

$num1 = rand(1, 9);
if($num1=='1')
{
$lala = "Main Menu";
}if($num1=='2')
{
$lala = "Shout Box";
}if($num1=='3')
{
$lala = "Lyric Menu";
}if($num1=='4')
{
$lala = "Buddies List";
}if($num1=='5')
{
$lala = "Inbox Menu";
}if($num1=='6')
{
$lala = "Main Forum";
}if($num1=='7')
{
$lala = "All Online List";
}if($num1=='8')
{
$lala = "F.A.Q Menu";
}if($num1=='9')
{
$lala = "Viewing Users Profile";
}

  mysql_query("INSERT INTO mx_online SET userid='".$pm[0]."', actvtime='".time()."', place='".$lala."'");

  }
 echo "Done!!<br/><br/>";
 }else{
 echo "You Can Do That!!<br/><br/>";
 }
 echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
echo "Home</a>";
include("wapv.php");

  echo "</p>";
    echo "</body>";
}
else if($show=="delcat")
{
  $fcid = $_POST["fcid"];
            echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"MaxHits.CO.CC\">";
      echo "<p align=\"center\">";
        echo $fcname;
        echo "<br/>";
        $res = mysql_query("DELETE FROM mx_fcats WHERE id='".$fcid."'");

        if($res)
      {
        echo "<img src=\"images/ok.gif\" alt=\"O\"/>Forum Category deleted successfully";
      }else{
        echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error deleting Forum Category";
      }

      echo "<br/><br/><a href=\"ownercp.php?show=fcats&amp;hits=$hits\">";
  echo "Forum Categories</a><br/>";
      echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"*\"/>";
  echo "Owner CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
  echo "Home</a>";
include("wapv.php");

      echo "</p></body>";
}
else if($show=="edtcat")
{
  $fcid = $_POST["fcid"];
  $fcname = $_POST["fcname"];
  $fcpos = $_POST["fcpos"];
            echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"MaxHits.CO.CC\">";
      echo "<p align=\"center\">";
        echo $fcname;
        echo "<br/>";
        $res = mysql_query("UPDATE mx_fcats SET name='".$fcname."', position='".$fcpos."' WHERE id='".$fcid."'");

        if($res)
      {
        echo "<img src=\"images/ok.gif\" alt=\"O\"/>Forum Category updated successfully";
      }else{
        echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error updating Forum Category";
      }

      echo "<br/><br/><a href=\"ownercp.php?show=fcats&amp;hits=$hits\">";
  echo "Forum Categories</a><br/>";
      echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"*\"/>";
  echo "Owner CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
  echo "Home</a>";
include("wapv.php");

      echo "</p></body>";
}
else if($show=="addcat")
{
  $fcname = $_POST["fcname"];
  $fcpos = $_POST["fcpos"];
            echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"MaxHits.CO.CC\">";
      echo "<p align=\"center\">";
        echo $fcname;
        echo "<br/>";
        $res = mysql_query("INSERT INTO mx_fcats SET name='".$fcname."', position='".$fcpos."'");
        
        if($res)
      {
        echo "<img src=\"images/ok.gif\" alt=\"O\"/>Forum Category added successfully";
      }else{
        echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error adding Forum Category";
      }

      echo "<br/><br/><a href=\"ownercp.php?show=fcats&amp;hits=$hits\">";
  echo "Forum Categories</a><br/>";
      echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"*\"/>";
  echo "Owner CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
  echo "Home</a>";
include("wapv.php");

      echo "</p></body>";
}
else if($show=="delfrm")
{
  $fid = $_POST["fid"];
            echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"MaxHits.CO.CC\">";
      echo "<p align=\"center\">";
        
        echo "<br/>";
        $res = mysql_query("DELETE FROM mx_forums WHERE id='".$fid."'");

        if($res)
      {
        echo "<img src=\"images/ok.gif\" alt=\"O\"/>Forum  deleted successfully";
      }else{
        echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error deleting Forum ";
      }

      echo "<br/><br/><a href=\"ownercp.php?show=forums&amp;hits=$hits\">";
  echo "Forums</a><br/>";
      echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"*\"/>";
  echo "Owner CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
  echo "Home</a>";

include("wapv.php");

      echo "</p></body>";
}
else if($show=="edtfrm")
{
  $fid = $_POST["fid"];
  $frname = $_POST["frname"];
  $frpos = $_POST["frpos"];
  $fcid = $_POST["fcid"];
            echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"MaxHits.CO.CC\">";
      echo "<p align=\"center\">";
        echo $frname;
        echo "<br/>";
        $res = mysql_query("UPDATE mx_forums SET name='".$frname."', position='".$frpos."', cid='".$fcid."' WHERE id='".$fid."'");

        if($res)
      {
        echo "<img src=\"images/ok.gif\" alt=\"O\"/>Forum  updated successfully";
      }else{
        echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error updating Forum ";
      }

      echo "<br/><br/><a href=\"ownercp.php?show=forums&amp;hits=$hits\">";
  echo "Forums</a><br/>";
      echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"*\"/>";
  echo "Owner CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
  echo "Home</a>";
include("wapv.php");

      echo "</p></body>";
}
else if($show=="addfrm")
{
  $frname = $_POST["frname"];
  $frpos = $_POST["frpos"];
  $fcid = $_POST["fcid"];
            echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"MaxHits.CO.CC\">";
      echo "<p align=\"center\">";
        echo $frname;
        echo "<br/>";
        $res = mysql_query("INSERT INTO mx_forums SET name='".$frname."', position='".$frpos."', cid='".$fcid."'");

        if($res)
      {
        echo "<img src=\"images/ok.gif\" alt=\"O\"/>Forum  added successfully";
      }else{
        echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error adding Forum ";
      }

      echo "<br/><br/><a href=\"ownercp.php?show=forums&amp;hits=$hits\">";
  echo "Forums</a><br/>";
      echo "<a href=\"ownercp.php?show=ownercp&amp;hits=$hits\"><img src=\"images/admn.gif\" alt=\"*\"/>";
  echo "Owner CP</a><br/>";
  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
  echo "Home</a>";
include("wapv.php");

      echo "</p></body>";
}
//////////////////////////error//////////////////////////
///////////////////////////////////////Unban user

else if($show=="unbn")
{
  $who = $_GET["who"];
         echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
  ///echo "<card=\"main\" title=\"Founder CP\">";
  echo "<p align=\"center\">";
  $res = mysql_query("DELETE FROM mx_penalties WHERE (penalty='1' OR penalty='2') AND uid='".$who."'");
  if($res)
          {
            $unick = getnick_uid($who);
            mysql_query("INSERT INTO mx_mlog SET action='penalties', details='<b>".getnick_uid(getuid_hits($hits))."</b> Unbanned The user <b>".$unick."</b>', actdt='".time()."'");
            echo "<img src=\"images/ok.gif\" alt=\"O\"/>$unick Unbanned";
          }else{
            echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error";
          }
  echo "<br/><br/>";


  echo "<a href=\"index.php?show=main&amp;hits=$hits\"><img src=\"images/home.gif\" alt=\"*\"/>";
echo "Home</a>";
include("wapv.php");
  echo "</p></body>";
}
else{
       echo "<head>";
  echo "<title>RemiXchaT.CoM - World Wide Chat Community And Downloads !</title>";
  include("inc/css.inc.php");
 echo "</head>";
 echo "<body>";
   echo getpagerror();
   echo "</body>";
}
?>
</html>