View file wapirate/A1/lovehate.php

File size: 6.03Kb
<?php

include("config.php");

include("core.php");

//sidsion_start();

header("Content-type: text/vnd.wap.wml");

header("Cache-Control: no-store, no-cache, must-revalidate");

echo("<?xml version=\"1.0\"?>");

echo "<!DOCTYPE wml PUBLIC \"-//WAPFORUM//DTD WML 1.1//EN\"". " \"http://www.wapforum.org/DTD/wml_1.1.xml\">";



?>



<wml>





<?php



$bcon = connectdb();

if (!$bcon)

{

    echo "<card id=\"main\" title=\"wapirate(ERROR!)\">";

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

    echo "<img src=\"images/exit.gif\" alt=\"*\"/><br/>";

    echo "SITE IS DOWN<br/><br/>";

    echo "<br/><br/>";

    echo "<b>seeing is believeing</b>";

    echo "</p>";

    echo "</card>";

    echo "</wml>";

    exit();

}

$brws = explode(" ",$HTTP_USER_AGENT);

$ubr = $brws[0];

$uip = getip();

$action = $_GET["action"];

$sid = $_GET["sid"];

$page = $_GET["page"];

$who = $_GET["who"];

$uid = getuid_sid($sid);

$wnick = getnick_uid($who);

cleardata();

if(isipbanned($uip,$ubr))

    {

      if(!isshield(getuid_sid($sid)))

      {

        echo "<card id=\"main\" title=\"wapirate\">";

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

      echo "<img src=\"images/notok.gif\" alt=\"x\"/><br/>";

      echo "This IP address is blocked<br/>";

      echo "<br/>";

      echo "How ever we grant a shield against IP-Ban for our great users, you can try to see if you are shielded by trying to log-in, if you kept coming to this page that means you are not shielded, so come back when the ip-ban period is over<br/><br/>";

      $banto = mysql_fetch_array(mysql_query("SELECT  timeto FROM ibwf_penalties WHERE  penalty='2' AND ipadd='".$uip."' AND browserm='".$ubr."' LIMIT 1 "));

      //echo mysql_error();

      $remain =  $banto[0] - time();

      $rmsg = gettimemsg($remain);

      echo " IP: $rmsg<br/><br/>";

      

      echo "</p>";

      echo "<p>";

  echo "UserID: <input name=\"loguid\" format=\"*x\" maxlength=\"30\"/><br/>";

  echo "Password: <input type=\"password\" name=\"logpwd\"  maxlength=\"30\"/><br/>";

  echo "<anchor>LOGIN<go href=\"login.php\" method=\"get\">";

  echo "<postfield name=\"loguid\" value=\"$(loguid)\"/>";

  echo "<postfield name=\"logpwd\" value=\"$(logpwd)\"/>";

  echo "</go></anchor>";

  echo "</p>";

      echo "</card>";

      echo "</wml>";

      exit();

      }

    }

if(($action != "") && ($action!="terms"))

{

    $uid = getuid_sid($sid);

    if((islogged($sid)==false)||($uid==0))

    {

        echo "<card id=\"main\" title=\"wapirate\">";

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

      echo "You are not logged in<br/>";

      echo "Or Your sidsion has been expired<br/><br/>";

      echo "<a href=\"index.php\">Login</a>";

      echo "</p>";

      echo "</card>";

      echo "</wml>";

      exit();

    }

    

    

    

}

//echo isbanned($uid);

if(isbanned($uid))

    {

        echo "<card id=\"main\" title=\"wapirate\">";

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

      echo "<img src=\"images/notok.gif\" alt=\"x\"/><br/>";

      echo "You are <b>Banned</b><br/>";

      $banto = mysql_fetch_array(mysql_query("SELECT timeto FROM ibwf_penalties WHERE uid='".$uid."' AND penalty='1'"));

	  $banres = mysql_fetch_array(mysql_query("SELECT lastpnreas FROM ibwf_users WHERE id='".$uid."'"));

	  

      $remain = $banto[0]- time();

      $rmsg = gettimemsg($remain);

      echo "Time to finish your penalty: $rmsg<br/><br/>";

	  echo "Ban Reason: $banres[0]";

      //echo "<a href=\"index.php\">Login</a>";

      echo "</p>";

      echo "</card>";

      echo "</wml>";

      exit();

    }





////////////////////////////////////////MAIN PAGE

if($action=="index")

{

  addvisitor();

  addonline(getuid_sid($sid),"Online List","");

  //saveuinfo($sid);

  echo "<card id=\"main\" title=\"$wnick's Anonymous PM\">";

  echo "<br/><br/>";

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

  echo "Send Anonymous Hate Mail to $wnick<br/>";

  echo "</p>";

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

  echo "<a href=\"lovehate.php?action=hate&amp;sid=$sid&amp;who=$who\">Send!</a>";

  echo "<img src=\"/smilies/ndevil.gif\" alt=\"*\"/>";

  echo "</p>";

  echo "<br/><br/>";

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

  echo "Send Anonymous Love Mail to $wnick<br/>";

  echo "</p>";

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

  echo "<a href=\"lovehate.php?action=love&amp;sid=$sid&amp;who=$who\">Send!</a>";

  echo "<img src=\"/smilies/angel.gif\" alt=\"*\"/>";

  echo "</p>";    



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

  

  echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>Home</a>";

  echo "</p>";

 echo "</card>";

}

else if($action=="hate")

{

  echo "<card id=\"main\" title=\"$wnick's Hate Mail\">";

 addonline(getuid_sid($sid),"Online List","");

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



		$message = "Somebody Anonymous Thinks You Have Smelly Feet! :stink :vomit[br/][small][i]p.s: this is an automated pm[/i][/small]";

	autopm2($message, $who);

	echo "Your really Mean! <br/>";

        echo "Anonymous Message Sent to $wnick.<br/>";

        echo "<img src=\"/smilies/ndevil.gif\" alt=\"*\"/>";

        echo "<br/></p>";



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

    echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>Home</a>";

  echo "</p>";

 echo "</card>";

}

else if($action=="love")

{

  echo "<card id=\"main\" title=\"$wnick's Love Mail\">";

 addonline(getuid_sid($sid),"Online List","");

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



    		$message = "Somebody Anonymous Thinks You Are Gorgeous :hug :love[br/][small][i]p.s: this is an automated pm[/i][/small]";

	autopm3($message, $who);

	echo "Your really Nice! <br/>";

        echo "Anonymous Message Sent to $wnick.<br/>";

        echo "<img src=\"/smilies/angel.gif\" alt=\"*\"/>";

        echo "<br/></p>";



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

    echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>Home</a>";

  echo "</p>";

 echo "</card>";

}

 ?>

</wml>