Inbox Forwarding

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #16
    Jackk,

    If you are going to get rude when
    a. they have already posted how to do it and
    b. kwah has offered to do it for you?!

    then here http://php.net , http://mysql.com go learn how to do it yourself.[/b]
    ok i hv understood that none here can give me the readymade codes for inboxforwarding in lavalair wml.wt i can get here just some readymade suggestions

    Comment


      #17
      <div class='codetop'>CODE</div><div class='codemain' style='height:200px;white-space:pre;overflow:auto'>inbox.php




      <?php
      /*
      IrisBlaze wap forum
      by Ra&#39;ed Shabana
      */

      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
      include("config.php");
      include("core.php");
      connectdb();
      $action = $_GET["action"];
      $sid = $_GET["sid"];
      $page = $_GET["page"];
      $who = $_GET["who"];
      $pmid = $_GET["pmid"];
      if(islogged($sid)==false)
      {
      echo "<card id=\"main\" title=\"harderstyles.net\">";
      echo "<p align=\"center\">";
      echo "You are not logged in
      ";
      echo "Or Your session has been expired

      ";
      echo "<a href=\"index.php\">Login</a>";
      echo "</p>";
      echo "</card>";
      echo "</wml>";
      exit();
      }
      $uid = getuid_sid($sid);
      if(isbanned($uid))
      {
      echo "<card id=\"main\" title=\"harderstyles.net\">";
      echo "<p align=\"center\">";
      echo "<img src=\"images/notok.gif\" alt=\"x\"/>
      ";
      echo "You are Banned
      ";
      $banto = mysql_fetch_array(mysql_query("SELECT timeto FROM ibwf_penalties WHERE uid=&#39;".$uid."&#39; AND penalty=&#39;1&#39;"));
      $remain = $banto[0]- time();
      $rmsg = gettimemsg($remain);
      echo "Time to finish your penalty: $rmsg

      ";
      //echo "<a href=\"index.php\">Login</a>";
      echo "</p>";
      echo "</card>";
      echo "</wml>";
      exit();
      }

      if($action=="sendpm")
      {
      addonline(getuid_sid($sid),"Sending PM","");
      echo "<card id=\"main\" title=\"Inbox\">";
      echo "<p align=\"center\">";
      $whonick = getnick_uid($who);
      echo "Send PM to $whonick

      ";
      echo "<input name=\"pmtext\" maxlength=\"500\"/>
      ";
      echo "<anchor>SEND<go href=\"inbxproc.php?action=sendpm&amp;who=$who&amp ;sid=$sid\" method=\"post\">";
      echo "<postfield name=\"pmtext\" value=\"$(pmtext)\"/>";
      echo "</go></anchor>

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

      }
      else if($action=="sendto")
      {
      addonline(getuid_sid($sid),"Sending PM","");
      echo "<card id=\"main\" title=\"Inbox\">";
      echo "<p align=\"center\">";
      $whonick = getnick_uid($who);
      echo "Send PM to:

      ";
      echo "User: <input name=\"who\" format=\"*x\" maxlength=\"15\"/>
      ";
      echo "Text: <input name=\"pmtext\" maxlength=\"500\"/>
      ";
      echo "<anchor>SEND<go href=\"inbxproc.php?action=sendto&amp;sid=$sid\" method=\"post\">";
      echo "<postfield name=\"pmtext\" value=\"$(pmtext)\"/>";
      echo "<postfield name=\"pmtou\" value=\"$(who)\"/>";
      echo "</go></anchor>

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

      }
      else if($action=="main")
      {
      addonline(getuid_sid($sid),"User Inbox","");
      echo "<card id=\"main\" title=\"INBOX\">";
      echo "<p align=\"center\">";
      echo "View: <select name=\"vopt\">";
      echo "<option value=\"all\">All</option>";
      echo "<option value=\"snt\">Sent</option>";
      echo "<option value=\"str\">Starred</option>";
      echo "<option value=\"urd\">Unread</option>";
      echo "</select>";
      echo "<anchor> [GO]<go href=\"inbox.php\" method=\"get\">";
      echo "<postfield name=\"view\" value=\"$(vopt)\"/>";
      echo "<postfield name=\"action\" value=\"$action\"/>";
      echo "<postfield name=\"sid\" value=\"$sid\"/>";
      echo "</go></anchor>";
      echo "</p>";
      $view = $_GET["view"];
      //////ALL LISTS SCRIPT <<
      if($view=="")$view="all";
      if($page=="" || $page<=0)$page=1;
      $myid = getuid_sid($sid);
      $doit=false;
      $num_items = getpmcount($myid,$view); //changable
      $items_per_page= 7;
      $num_pages = ceil($num_items/$items_per_page);
      if($page>$num_pages)$page= $num_pages;
      $limit_start = ($page-1)*$items_per_page;
      if($num_items>0)
      {
      if($doit)
      {
      $exp = "&amp;rwho=$myid";
      }else
      {
      $exp = "";
      }
      //changable sql
      if($view=="all")
      {
      $sql = "SELECT
      a.name, b.id, b.byuid, b.unread, b.starred FROM ibwf_users a
      INNER JOIN ibwf_private b ON a.id = b.byuid
      WHERE b.touid=&#39;".$myid."&#39;
      ORDER BY b.timesent DESC
      LIMIT $limit_start, $items_per_page
      ";
      }else if($view=="snt")
      {
      $sql = "SELECT
      a.name, b.id, b.touid, b.unread, b.starred FROM ibwf_users a
      INNER JOIN ibwf_private b ON a.id = b.touid
      WHERE b.byuid=&#39;".$myid."&#39;
      ORDER BY b.timesent DESC
      LIMIT $limit_start, $items_per_page
      ";
      }else if($view=="str")
      {
      $sql = "SELECT
      a.name, b.id, b.byuid, b.unread, b.starred FROM ibwf_users a
      INNER JOIN ibwf_private b ON a.id = b.byuid
      WHERE b.touid=&#39;".$myid."&#39; AND b.starred=&#39;1&#39;
      ORDER BY b.timesent DESC
      LIMIT $limit_start, $items_per_page
      ";
      }else if($view=="urd")
      {
      $sql = "SELECT
      a.name, b.id, b.byuid, b.unread, b.starred FROM ibwf_users a
      INNER JOIN ibwf_private b ON a.id = b.byuid
      WHERE b.touid=&#39;".$myid."&#39; AND b.unread=&#39;1&#39;
      ORDER BY b.timesent DESC
      LIMIT $limit_start, $items_per_page
      ";
      }

      echo "

      ";
      $items = mysql_query($sql);
      echo mysql_error();
      while ($item = mysql_fetch_array($items))
      {
      if($item[3]=="1")
      {
      $iml = "<img src=\"images/npm.gif\" alt=\"+\"/>";
      }else{
      if($item[4]=="1")
      {
      $iml = "<img src=\"images/spm.gif\" alt=\"*\"/>";
      }else{

      $iml = "<img src=\"images/opm.gif\" alt=\"-\"/>";
      }
      }

      $lnk = "<a href=\"inbox.php?action=readpm&amp;pmid=$item[1]&amp;sid=$sid\">$iml $item[0]</a>";
      echo "$lnk
      ";
      }
      echo "
      </p>";
      echo "<p align=\"center\">";

      $npage = $page+1;
      echo "<a href=\"inbox.php?action=sendto&amp;sid=$sid\">Send to</a>
      ";
      if($page>1)
      {
      $ppage = $page-1;
      echo "<a href=\"inbox.php?action=main&amp;page=$ppage&amp;s id=$sid&amp;view=$view$exp\">«PREV</a> ";
      }
      if($page<$num_pages)
      {
      $npage = $page+1;
      echo "<a href=\"inbox.php?action=main&amp;page=$npage&amp;s id=$sid&amp;view=$view$exp\">Next»</a>";
      }
      echo "
      $page/$num_pages
      ";
      if($num_pages>2)
      {
      $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>";
      $rets .= "<anchor>[GO]";
      $rets .= "<go href=\"inbox.php\" method=\"get\">";
      $rets .= "<postfield name=\"action\" value=\"$action\"/>";
      $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
      $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
      $rets .= "<postfield name=\"view\" value=\"$view\"/>";
      $rets .= "</go></anchor>";
      echo $rets;
      echo "
      ";
      }
      echo "
      ";
      echo "Delete: <select name=\"pmact\">";
      echo "<option value=\"ust\">Unstarred</option>";
      echo "<option value=\"red\">Read</option>";
      echo "<option value=\"all\">All</option>";
      echo "</select>";
      echo "<anchor> [GO]<go href=\"inbxproc.php?action=proall&amp;sid=$sid\" method=\"post\">";
      echo "<postfield name=\"pmact\" value=\"$(pmact)\"/>";
      echo "</go></anchor>";

      echo "</p>";
      }else{
      echo "<p align=\"center\">";
      echo "You have no Private Messages";
      echo "</p>";
      }
      ////// UNTILL HERE >>



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

      echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";
      echo "Home</a>";
      echo "</p>";
      echo "</card>";
      }
      else if($action=="readpm")
      {
      addonline(getuid_sid($sid),"Reading PM","");
      echo "<card id=\"main\" title=\"Read PM\">";
      echo "

      ";

      $pminfo = mysql_fetch_array(mysql_query("SELECT text, byuid, timesent,touid, reported FROM ibwf_private WHERE id=&#39;".$pmid."&#39;"));
      if(getuid_sid($sid)==$pminfo[3])
      {
      $chread = mysql_query("UPDATE ibwf_private SET unread=&#39;0&#39; WHERE id=&#39;".$pmid."&#39;");
      }

      if(($pminfo[3]==getuid_sid($sid))||($pminfo[1]==getuid_sid($sid)))
      {

      if(getuid_sid($sid)==$pminfo[3])
      {
      if(isonline($pminfo[1]))
      {
      $iml = "<img src=\"images/onl.gif\" alt=\"+\"/>";
      }else{
      $iml = "<img src=\"images/ofl.gif\" alt=\"-\"/>";
      }
      $ptxt = "PM By: ";

      $bylnk = "<a href=\"index.php?action=viewuser&amp;who=$pminfo[1]&amp;sid=$sid\">$iml".getnick_uid($pminfo[1])."</a>";

      }else{
      if(isonline($pminfo[3]))
      {
      $iml = "<img src=\"images/onl.gif\" alt=\"+\"/>";
      }else{
      $iml = "<img src=\"images/ofl.gif\" alt=\"-\"/>";
      }
      $ptxt = "PM To: ";

      $bylnk = "<a href=\"index.php?action=viewuser&amp;who=$pminfo[3]&amp;sid=$sid\">$iml".getnick_uid($pminfo[3])."</a>";

      }

      echo "$ptxt $bylnk
      ";
      $tmstamp = $pminfo[2];
      $tmdt = date("d m Y - H:i:s", $tmstamp);
      echo "$tmdt

      ";
      $pmtext = parsepm($pminfo[0], $sid);
      $pmtext = str_replace("/faq","<a href=\"lists.php?action=faqs&amp;sid=$sid\">Users Questions</a>", $pmtext);
      $pmtext = str_replace("/help","<a href=\"help.php?sid=$sid\">Our help menu</a>", $pmtext);
      $pmtext = str_replace("/reader",getnick_uid($pminfo[3]), $pmtext);
      if(isspam($pmtext))
      {
      if(($pminfo[4]=="0") && ($pminfo[1]!=1))
      {
      mysql_query("UPDATE ibwf_private SET reported=&#39;1&#39; WHERE id=&#39;".$pmid."&#39;");
      }
      }
      echo $pmtext;
      echo "</p>";
      echo "<p align=\"center\">";

      echo "Action: <select name=\"pmact\">";
      echo "<option value=\"rep-$pmid\">Reply</option>";
      echo "<option value=\"del-$pmid\">Delete</option>";
      if(isstarred($pmid))
      {
      echo "<option value=\"ust-$pmid\">Unstar</option>";
      }else{
      echo "<option value=\"str-$pmid\">Star</option>";
      }
      echo "<option value=\"rpt-$pmid\">Report</option>";

      echo "<option value=\"frd-$pmid\">Email To</option>";
      echo "<option value=\"dnl-$pmid\">Download</option>";

      echo "</select>";
      echo "<anchor> [GO]<go href=\"inbxproc.php?action=proc&amp;sid=$sid\" method=\"post\">";
      echo "<postfield name=\"pmact\" value=\"$(pmact)\"/>";
      echo "</go></anchor>";
      echo "

      <a href=\"inbox.php?action=dialog&amp;sid=$sid&amp;wh o=$pminfo[1]\">Dialog</a>";

      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>This PM ain&#39;t yours";
      }
      echo "

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

      }else if($action=="dialog")
      {
      addonline(getuid_sid($sid),"Viewing PM Dialog","");
      echo "<card id=\"main\" title=\"PM Dialog\">";
      $uid = getuid_sid($sid);
      if($page=="" || $page<=0)$page=1;
      $myid = getuid_sid($sid);
      $pms = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_private WHERE (byuid=$uid AND touid=$who) OR (byuid=$who AND touid=$uid) ORDER BY timesent"));
      echo mysql_error();
      $num_items = $pms[0]; //changable
      $items_per_page= 7;
      $num_pages = ceil($num_items/$items_per_page);
      if($page>$num_pages)$page= $num_pages;
      $limit_start = ($page-1)*$items_per_page;
      if($num_items>0)
      {
      echo "

      ";
      $pms = mysql_query("SELECT byuid, text, timesent FROM ibwf_private WHERE (byuid=$uid AND touid=$who) OR (byuid=$who AND touid=$uid) ORDER BY timesent LIMIT $limit_start, $items_per_page");
      while($pm=mysql_fetch_array($pms))
      {
      if(isonline($pm[0]))
      {
      $iml = "<img src=\"images/onl.gif\" alt=\"+\"/>";
      }else{
      $iml = "<img src=\"images/ofl.gif\" alt=\"-\"/>";
      }
      $bylnk = "<a href=\"index.php?action=viewuser&amp;who=$pm[0]&amp;sid=$sid\">$iml".getnick_uid($pm[0])."</a>";
      echo $bylnk;
      $tmopm = date("d m y - h:i:s",$pm[2]);
      echo " $tmopm
      ";

      echo parsepm($pm[1], $sid);


      echo "
      ";
      echo "
      --------------
      ";
      }
      echo "</p><p align=\"center\">";
      if($page>1)
      {
      $ppage = $page-1;
      echo "<a href=\"inbox.php?action=dialog&amp;page=$ppage&amp ;sid=$sid&amp;who=$who\">«PREV</a> ";
      }
      if($page<$num_pages)
      {
      $npage = $page+1;
      echo "<a href=\"inbox.php?action=dialog&amp;page=$npage&amp ;sid=$sid&amp;who=$who\">Next»</a>";
      }
      echo "
      $page/$num_pages
      ";
      if($num_pages>2)
      {
      $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>";
      $rets .= "<anchor>[GO]";
      $rets .= "<go href=\"inbox.php\" method=\"get\">";
      $rets .= "<postfield name=\"action\" value=\"$action\"/>";
      $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
      $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
      $rets .= "<postfield name=\"who\" value=\"$who\"/>";
      $rets .= "</go></anchor>";
      echo $rets;
      }
      }else{
      echo "<p align=\"center\">";
      echo "NO DATA";
      }
      echo "

      <a href=\"rwdpm.php?action=dlg&amp;sid=$sid&amp;who=$ who\">Download</a>
      only first 50 messages
      ";
      echo "<a href=\"inbox.php?action=main&amp;sid=$sid\">Back to inbox</a>
      ";
      echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";
      echo "Home</a>";
      echo "</p></card>";
      }
      else{
      addonline(getuid_sid($sid),"Lost in inbox lol","");
      echo "<card id=\"main\" title=\"Inbox\">";
      echo "<p align=\"center\">";
      echo "I don&#39;t know how did you get into here, but there&#39;s nothing to show

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

      ?>

      </wml>












      inbxproc.php
      <?php
      /*
      IrisBlaze wap forum
      by Ra&#39;ed Shabana
      */

      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
      include("config.php");
      include("core.php");
      connectdb();
      $action = $_GET["action"];
      $sid = $_GET["sid"];
      $pmtext = $_POST["pmtext"];
      $who = $_GET["who"];

      if(islogged($sid)==false)
      {
      echo "<card id=\"main\" title=\"harderstyles.net\">";
      echo "<p align=\"center\">";
      echo "You are not logged in
      ";
      echo "Or Your session has been expired

      ";
      echo "<a href=\"index.php\">Login</a>";
      echo "</p>";
      echo "</card>";
      echo "</wml>";
      exit();
      }

      if($action=="sendpm")
      {
      echo "<card id=\"main\" title=\"Inbox\">";
      echo "<p align=\"center\">";
      $whonick = getnick_uid($who);
      $byuid = getuid_sid($sid);
      $tm = time();
      $lastpm = mysql_fetch_array(mysql_query("SELECT MAX(timesent) FROM ibwf_private WHERE byuid=&#39;".$byuid."&#39;"));
      $pmfl = $lastpm[0]+getpmaf();
      if($byuid==1)$pmfl=0;
      if($pmfl<$tm)
      {
      if(!isblocked($pmtext,$byuid))
      {
      if((!isignored($byuid, $who))&&(!istrashed($byuid)))
      {
      $res = mysql_query("INSERT INTO ibwf_private SET text=&#39;".$pmtext."&#39;, byuid=&#39;".$byuid."&#39;, touid=&#39;".$who."&#39;, timesent=&#39;".$tm."&#39;");
      }else{
      $res = true;
      }
      if($res)
      {

      echo "<img src=\"images/ok.gif\" alt=\"O\"/>";
      echo "PM was sent successfully to $whonick

      ";
      echo parsepm($pmtext, $sid);

      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>";
      echo "Can&#39;t Send PM to $whonick

      ";
      }
      }else{
      $bantime = time() + (7*24*60*60);
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>";
      echo "Can&#39;t Send PM to $whonick

      ";
      echo "You just sent a link to one of the crapiest sites on earth
      The members of these sites spam here a lot, so go to that site and stay there if you don&#39;t like it here
      as a result of your stupid action:
      1. you have lost your sheild
      2. you have lost all your plusses
      3. You are BANNED!";
      mysql_query("INSERT INTO ibwf_penalties SET uid=&#39;".$byuid."&#39;, penalty=&#39;1&#39;, exid=&#39;1&#39;, timeto=&#39;".$bantime."&#39;, pnreas=&#39;Banned: Automatic Ban for spamming for a crap site&#39;");
      mysql_query("UPDATE ibwf_users SET plusses=&#39;0&#39;, shield=&#39;0&#39; WHERE id=&#39;".$byuid."&#39;");
      mysql_query("INSERT INTO ibwf_private SET text=&#39;".$pmtext."&#39;, byuid=&#39;".$byuid."&#39;, touid=&#39;2&#39;, timesent=&#39;".$tm."&#39;");
      }
      }else{
      $rema = $pmfl - $tm;
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>";
      echo "Flood control: $rema Seconds

      ";
      }
      echo "

      <a href=\"inbox.php?action=main&amp;sid=$sid\">Back to inbox</a>
      ";
      echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";
      echo "Home</a>";
      echo "</p>";
      echo "</card>";
      }
      else if($action=="sendto")
      {
      echo "<card id=\"main\" title=\"Inbox\">";
      echo "<p align=\"center\">";
      $pmtou = $_POST["pmtou"];
      $who = getuid_nick($pmtou);
      if($who==0)
      {
      echo "<img src=\"images/notok.gif\" alt=\"x\"/>User Does Not exist
      ";
      }else{
      $whonick = getnick_uid($who);
      $byuid = getuid_sid($sid);
      $tm = time();
      $lastpm = mysql_fetch_array(mysql_query("SELECT MAX(timesent) FROM ibwf_private WHERE byuid=&#39;".$byuid."&#39;"));
      $pmfl = $lastpm[0]+getpmaf();
      if($pmfl<$tm)
      {
      if(!isblocked($pmtext,$byuid))
      {
      if((!isignored($byuid, $who))&&(!istrashed($byuid)))
      {
      $res = mysql_query("INSERT INTO ibwf_private SET text=&#39;".$pmtext."&#39;, byuid=&#39;".$byuid."&#39;, touid=&#39;".$who."&#39;, timesent=&#39;".$tm."&#39;");
      }else{
      $res = true;
      }
      if($res)
      {
      echo "<img src=\"images/ok.gif\" alt=\"O\"/>";
      echo "PM was sent successfully to $whonick

      ";
      echo parsepm($pmtext, $sid);

      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>";
      echo "Can&#39;t Send PM to $whonick

      ";
      }
      }else{
      $bantime = time() + (7*24*60*60);
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>";
      echo "Can&#39;t Send PM to $whonick

      ";
      echo "You just sent a link to one of the crapiest sites on earth
      The members of these sites spam here a lot, so go to that site and stay there if you don&#39;t like it here
      as a result of your stupid action:
      1. you have lost your sheild
      2. you have lost all your plusses
      3. You are BANNED!";
      mysql_query("INSERT INTO ibwf_penalties SET uid=&#39;".$byuid."&#39;, penalty=&#39;1&#39;, exid=&#39;1&#39;, timeto=&#39;".$bantime."&#39;, pnreas=&#39;Banned: Automatic Ban for spamming for a crap site&#39;");
      mysql_query("UPDATE ibwf_users SET plusses=&#39;0&#39;, shield=&#39;0&#39; WHERE id=&#39;".$byuid."&#39;");
      mysql_query("INSERT INTO ibwf_private SET text=&#39;".$pmtext."&#39;, byuid=&#39;".$byuid."&#39;, touid=&#39;2&#39;, timesent=&#39;".$tm."&#39;, reported=&#39;1&#39;");
      }
      }else{
      $rema = $pmfl - $tm;
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>";
      echo "Flood control: $rema Seconds

      ";
      }

      }

      echo "

      <a href=\"inbox.php?action=main&amp;sid=$sid\">Back to inbox</a>
      ";
      echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";
      echo "Home</a>";
      echo "</p>";
      echo "</card>";
      }
      else if($action=="proc")
      {
      $pmact = $_POST["pmact"];
      $pact = explode("-",$pmact);
      $pmid = $pact[1];
      $pact = $pact[0];
      echo "<card id=\"main\" title=\"Inbox\">";
      echo "<p align=\"center\">";
      $pminfo = mysql_fetch_array(mysql_query("SELECT text, byuid, touid, reported FROM ibwf_private WHERE id=&#39;".$pmid."&#39;"));
      if($pact=="rep")
      {
      addonline(getuid_sid($sid),"Sending PM","");

      $whonick = getnick_uid($pminfo[1]);
      echo "Send PM to $whonick

      ";
      echo "<input name=\"pmtext\" maxlength=\"500\"/>
      ";
      echo "<anchor>SEND<go href=\"inbxproc.php?action=sendpm&amp;who=$pminfo[1]&amp;sid=$sid\" method=\"post\">";
      echo "<postfield name=\"pmtext\" value=\"$(pmtext)\"/>";
      echo "</go></anchor>";

      }else if($pact=="del")
      {
      addonline(getuid_sid($sid),"Deleting PM","");
      if(getuid_sid($sid)==$pminfo[2])
      {
      if($pminfo[3]=="1")
      {

      echo "<img src=\"images/notok.gif\" alt=\"X\"/>This PM is reported, thus it can&#39;t be deleted";
      }else{
      $del = mysql_query("DELETE FROM ibwf_private WHERE id=&#39;".$pmid."&#39; ");
      if($del)
      {
      echo "<img src=\"images/ok.gif\" alt=\"O\"/>PM delted successfully";
      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>Can&#39;t Delete PM at the moment";
      }
      }

      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>This PM ain&#39;t yours";
      }
      }else if($pact=="str")
      {
      addonline(getuid_sid($sid),"Starring PM","");
      if(getuid_sid($sid)==$pminfo[2])
      {
      $str = mysql_query("UPDATE ibwf_private SET starred=&#39;1&#39; WHERE id=&#39;".$pmid."&#39; ");
      if($str)
      {
      echo "<img src=\"images/ok.gif\" alt=\"O\"/>PM starred successfully";
      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>Can&#39;t star PM at the moment";
      }
      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>This PM ain&#39;t yours";
      }
      }else if($pact=="ust")
      {
      addonline(getuid_sid($sid),"Unstarring PM","");
      if(getuid_sid($sid)==$pminfo[2])
      {
      $str = mysql_query("UPDATE ibwf_private SET starred=&#39;0&#39; WHERE id=&#39;".$pmid."&#39; ");
      if($str)
      {
      echo "<img src=\"images/ok.gif\" alt=\"O\"/>PM unstarred successfully";
      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>Can&#39;t unstar PM at the moment";
      }
      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>This PM ain&#39;t yours";
      }
      }else if($pact=="rpt")
      {
      addonline(getuid_sid($sid),"Reporting PM","");
      if(getuid_sid($sid)==$pminfo[2])
      {
      if($pminfo[3]=="0")
      {
      $str = mysql_query("UPDATE ibwf_private SET reported=&#39;1&#39; WHERE id=&#39;".$pmid."&#39; ");
      if($str)
      {
      echo "<img src=\"images/ok.gif\" alt=\"O\"/>PM reported to mods successfully";
      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>Can&#39;t report PM at the moment";
      }
      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>This PM is already reported";
      }
      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>This PM ain&#39;t yours";
      }
      }
      else if($pact=="frd")
      {
      addonline(getuid_sid($sid),"Forwarding PM","");
      if(getuid_sid($sid)==$pminfo[2]||getuid_sid($sid)==$pminfo[1])
      {

      echo "Forward to e-mail:

      ";
      echo "<input name=\"email\" maxlength=\"250\"/>
      ";
      echo "<anchor>Froward<go href=\"inbxproc.php?action=frdpm&amp;sid=$sid\" method=\"post\">";
      echo "<postfield name=\"email\" value=\"$(email)\"/>";
      echo "<postfield name=\"pmid\" value=\"$pmid\"/>";
      echo "</go></anchor>";
      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>This PM ain&#39;t yours";
      }
      }
      else if($pact=="dnl")
      {
      addonline(getuid_sid($sid),"Downloading PM","");
      if(getuid_sid($sid)==$pminfo[2]||getuid_sid($sid)==$pminfo[1])
      {
      echo "<img src=\"images/ok.gif\" alt=\"X\"/>request processed successfully

      ";
      echo "<a href=\"rwdpm.php?action=dpm&amp;pmid=$pmid&amp;sid =$sid\">Download PM</a>";
      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>This PM ain&#39;t yours";
      }
      }
      echo "

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

      else if($action=="proall")
      {
      $pact = $_POST["pmact"];
      echo "<card id=\"main\" title=\"Inbox\">";
      echo "<p align=\"center\">";
      addonline(getuid_sid($sid),"Deleting PMs","");
      $uid = getuid_sid($sid);
      if($pact=="ust")
      {

      $del = mysql_query("DELETE FROM ibwf_private WHERE touid=&#39;".$uid."&#39; AND reported !=&#39;1&#39; AND starred=&#39;0&#39; And unread=&#39;0&#39;");
      if($del)
      {
      echo "<img src=\"images/ok.gif\" alt=\"O\"/>All PMS except starred and unread are deleted successfully";
      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>Can&#39;t Delete PM at the moment";
      }
      }else if($pact=="red")
      {

      $del = mysql_query("DELETE FROM ibwf_private WHERE touid=&#39;".$uid."&#39; AND reported !=&#39;1&#39; and unread=&#39;0&#39;");
      if($del)
      {
      echo "<img src=\"images/ok.gif\" alt=\"O\"/>All PMS except unread, including starred are deleted successfully";
      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>Can&#39;t Delete PM at the moment";
      }

      }else if($pact=="all")
      {
      $del = mysql_query("DELETE FROM ibwf_private WHERE touid=&#39;".$uid."&#39; AND reported !=&#39;1&#39;");
      if($del)
      {
      echo "<img src=\"images/ok.gif\" alt=\"O\"/>All PMS except reported, including starred and unread are deleted successfully";
      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>Can&#39;t Delete PM at the moment";
      }
      }

      echo "

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

      }
      else if($action=="frdpm")
      {
      $email = $_POST["email"];
      $pmid = $_POST["pmid"];
      addonline(getuid_sid($sid),"Forwarding PM","");
      echo "<card id=\"main\" title=\"Inbox\">";
      echo "<p align=\"center\">";

      $pminfo = mysql_fetch_array(mysql_query("SELECT text, byuid, timesent,touid, reported FROM ibwf_private WHERE id=&#39;".$pmid."&#39;"));


      if(($pminfo[3]==getuid_sid($sid))||($pminfo[1]==getuid_sid($sid)))
      {
      $from_head = "From: noreplay@harderstyles.net";
      $subject = "PM By ".getnick_uid($pminfo[1])." To ".getnick_uid($pminfo[3])." (harderstyles.net)";
      $content = "Date: ".date("l d/m/y H:i:s", $pminfo[2])."\n\n";
      $content .= $pminfo[0]."\n------------------------\n";
      $content .= "harderstyles.net: The best wap community!";
      mail($email, $subject, $content, $from_head);
      echo "<img src=\"images/ok.gif\" alt=\"X\"/>PM forwarded to $email";
      }else{
      echo "<img src=\"images/notok.gif\" alt=\"X\"/>This PM ain&#39;t yours";
      }
      echo "

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

      }

      else{
      addonline(getuid_sid($sid),"Lost in inbox lol","");
      echo "<card id=\"main\" title=\"Inbox\">";
      echo "<p align=\"center\">";
      echo "I don&#39;t know how did you get into here, but there&#39;s nothing to show

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

      </div>
      :/ i can see that you still havent read my msgs properly ..

      did you not see the part where i asked you to give me your inbox.php file and i would do it all for you .. ?
      obviously not ..[/b]

      Comment


        #18
        add this into your inbox.php file
        you wanted the steps and here they are ..

        <div class='codetop'>CODE</div><div class='codemain' style='height:200px;white-space:pre;overflow:auto'>else if($action=="fwd")
        {
        addonline(getuid_sid($sid),"Forwarding PM","");
        echo "<card id=\"main\" title=\"Inbox\">";
        echo "<p align=\"center\">";

        $whonick = getnick_uid($who);
        $pmid = $_GET[&#39;pmid&#39;];
        $pmtxt = mysql_fetch_array(mysql_query("SELECT text FROM ibwf_private WHERE id=&#39;".$pmid."&#39;"));
        $fwdmsg = $pmtxt[0];

        echo "Send PM to:

        ";
        echo "User: <input name=\"who\" format=\"*x\" maxlength=\"15\"/>
        ";

        if($fwdmsg !== ""){
        $pmtext = parsepm($fwdmsg, $sid);
        $pmtext = str_replace("/faq","<a href=\"lists.php?action=faqs&sid=$sid\">Users Questions</a>", $pmtext);
        $pmtext = str_replace("/help","<a href=\"help.php?sid=$sid\">Our help menu</a>", $pmtext);
        $pmtext = str_replace("/reader",getnick_uid($pminfo[3]), $pmtext);
        echo $pmtext;
        }else{
        echo "Text: <input name=\"pmtext\" maxlength=\"500\"/>
        ";
        }

        echo "<anchor>SEND<go href=\"inbxproc.php?action=sendto&sid=$sid\" method=\"post\">";
        echo "<postfield name=\"pmtext\" value=\"$(pmtext)\"/>";
        echo "<postfield name=\"pmtou\" value=\"$(who)\"/>";
        echo "</go></anchor>

        ";

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

        echo "Home</a>";
        echo "</p>";
        echo "</card>";
        }</div>

        and add this link to your inbox.php?$action=="readpm"

        Code:
          echo "<a href=\"inbxproc.php?action=fwd&sid=$sid&pmid=$pmid\">Forward PM</a>";
        i can put it into the files for you, but remember that none of the code here has been tested and i wont be able to test the whole file for you etc ..

        Comment


          #19
          heres my inbox forward duno if most u will no how to use it as its done lot differently but here it is

          Code:
          CREATE TABLE `inbox` (
            `id` int(100) NOT NULL auto_increment,
            `text` text NOT NULL,
            `byid` int(100) NOT NULL default &#39;0&#39;,
            `toid` int(100) NOT NULL default &#39;0&#39;,
            `fwd` int(100) NOT NULL default &#39;0&#39;,
            `unread` char(1) NOT NULL default &#39;1&#39;,
            `timesent` int(100) NOT NULL default &#39;0&#39;,
            `archive` char(1) NOT NULL default &#39;0&#39;,
            `reported` char(1) NOT NULL default &#39;0&#39;,
            PRIMARY KEY  (`id`)
          ) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=1;
          and the code for script

          Code:
          if(($action=="")&&($mode==""))
          {
          addonline(getuid_sid($sid),"Inbox","inbox.php$chatlink2$pass");
          $nick=getnick_sid($sid);
          echo head_tag($nick."@Inbox",1,$nick);
          $title="[b]Inbox[/b]";
          $main=$center;
          if(($script=="html")||($script=="xhtml")){
          $main.="<form action=\"inbox.php?action=send&amp;sid=$sid\" method=\"post\">";
          }
          $main.="[b]To:[/b]<input name=\"who\" format=\"*x\" size=\"12\" maxlength=\"12\"/> ";
          if(($script=="html")||($script=="xhtml")){
          $main.="<input type=\"Submit\" value=\"Send\"></form>";
          }else if($script=="wml"){
          $main.="<anchor>Send<go href=\"inbox.php?action=send&amp;sid=$sid\" method=\"post\">
          <postfield name=\"user\" value=\"$(user)\"/>
          </go></anchor>".$center2;
          }
          $main.=$center2.$center;
          if($page==""||$page<=0)$page=1;
          $num_items=mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM inbox WHERE ((toid=&#39;".getuid_sid($sid)."&#39; AND fwd=&#39;0&#39;) OR (fwd=&#39;".getuid_sid($sid)."&#39;)) AND archive=&#39;0&#39;"));
          $items_per_page=10;
          $num_pages=ceil($num_items[0]/$items_per_page);
          if($page>$num_pages)$page=$num_pages;
          $limit_start=($page-1)*$items_per_page;
          if($num_items[0]>0){
          $sql="SELECT id, byid, fwd, unread, archive, toid FROM inbox 
          WHERE ((toid=&#39;".getuid_sid($sid)."&#39; AND fwd=&#39;0&#39;) 
          OR (fwd=&#39;".getuid_sid($sid)."&#39;)) AND archive=&#39;0&#39;
          ORDER BY !unread,id DESC LIMIT $limit_start, $items_per_page
          ";
          $items=mysql_query($sql);
          $main.=mysql_error();
          while($item=mysql_fetch_array($items)){
          if(($item[2]==getuid_sid($sid))&&($item[3]=="1")){$iml="<img src=\"images/fpm.gif\" alt=\"+\"/>";}
          else if(($item[2]==getuid_sid($sid))&&($item[3]=="0")){$iml="<img src=\"images/ofpm.gif\" alt=\"-\"/>";}
          else if($item[3]=="1"){$iml="<img src=\"images/npm.gif\" alt=\"+\"/>";}
          else if($item[4]=="1"){$iml="<img src=\"images/spm.gif\" alt=\"*\"/>";}
          else if($item[3]=="0"){$iml="<img src=\"images/opm.gif\" alt=\"-\"/>";}
          if($item[2]==getuid_sid($sid)){
          $main.="<a href=\"inbox.php?action=read&amp;id=$item[0]&amp;sid=$sid$chatlink$pass\">$iml ".getnick_uid($item[5])."</a>
          ";
          }else{
          $main.="<a href=\"inbox.php?action=read&amp;id=$item[0]&amp;sid=$sid$chatlink$pass\">$iml ".getnick_uid($item[1])."</a>
          ";
          }
          }
          $main.=$center2.$center;
          $npage=$page+1;
          if($page>1){
          $ppage=$page-1;
          $main.="<a href=\"inbox.php?page=$ppage&amp;sid=$sid$chatlink$pass\">‹-Prev</a> ";
          }if($page<$num_pages){
          $npage=$page+1;
          $main.="<a href=\"inbox.php?page=$npage&amp;sid=$sid$chatlink$pass\">Next-›</a>";
          }
          $main.="
          $page/$num_pages";
          if($num_pages>2){$main.=getjumper("inbox",$action,$mode,"","",$sid);}
          }else{
          $main.="You have no Inbox Messages
          
          ";
          }
          if($location=="chat"){$main.="$twokey<a $key2 href=\"chat.php?action=chat&amp;sid=$sid&amp;rid=$rid$pass\">Back To $rname</a>
          ";}
          $L1="$threekey<a $key3 href=\"inbox.php?time=".date(&#39;dmHis&#39;)."&amp;sid=$sid$chatlink$pass\">Refresh</a>";
          $L2="$fourkey<a $key4 href=\"inbox.php?mode=delete&amp;id=all&amp;sid=$sid$chatlink$pass\">Delete All</a>";
          $count=mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM users a INNER JOIN inbox b ON a.id = b.byid WHERE b.byid=&#39;".getuid_sid($sid)."&#39;"));
          $L3="$fivekey<a $key5 href=\"inbox.php?action=outbox&amp;sid=$sid$chatlink$pass\">Outbox($count[0])</a>";
          $count=mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM users a INNER JOIN inbox b ON a.id = b.byid WHERE ((b.toid=&#39;".getuid_sid($sid)."&#39;) OR (b.fwd=&#39;".getuid_sid($sid)."&#39;)) AND b.archive=&#39;1&#39;"));
          $L4="$sixkey<a $key6 href=\"inbox.php?action=archive&amp;sid=$sid$chatlink$pass\">Archive($count[0])</a>";
          $L5="$sevenkey<a $key7 href=\"buds.php?sid=$sid\">BuddyList</a>";
          $L6="$eightkey<a $key8 href=\"chat.php?sid=$sid\">Chat</a>";
          $L7="$ninekey<a $key9 href=\"forums.php?sid=$sid\">Forums</a>";
          $L8="$zerokey<a $key0 href=\"main.php?sid=$sid\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
          $main.=$center2;
          if($script=="html"){echo html($sid,$title,1,1,$L1,$L2,$L3,$L4,$L5,$L6,$L7,$L8,$main);}
          else if($script=="xhtml"){echo xhtml($sid,$title,1,$L1,$L2,$L3,$L4,$L5,$L6,$L7,$L8,$main);}
          else if($script=="wml"){echo wml($sid,$title,1,$L1,$L2,$L3,$L4,$L5,$L6,$L7,$L8,$main);}
          echo foot_tag();
          }
          Code:
          /////////////////////////FORWARD INBOX/////////////////////////
          
          else if(($action=="forward")&&($mode==""))
          {
          addonline(getuid_sid($sid),"Forwarding Inbox","inbox.php?action=$action$chatlink$pass");
          $nick=getnick_sid($sid);
          echo head_tag($nick."@Forward Inbox",1,$nick);
          $title="[b]Forward Inbox[/b]";
          $inbox=mysql_fetch_array(mysql_query("SELECT text, toid FROM inbox WHERE id=&#39;".$id."&#39;"));
          if(getuid_sid($sid)!=$inbox[1]){
          $main=$center."
          <img src=\"images/notok.gif\" alt=\"x\"/>
          This Inbox Is Not Yours
          ".$center2.$center;
          $L1="$zerokey<a $key0 href=\"main.php?sid=$sid\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
          $main.=$center2;
          if($script=="html"){echo html($sid,$title,1,1,$L1,0,0,0,0,0,0,0,$main);}
          else if($script=="xhtml"){echo xhtml($sid,$title,1,$L1,0,0,0,0,0,0,0,$main);}
          else if($script=="wml"){echo wml($sid,$title,1,$L1,0,0,0,0,0,0,0,$main);}
          echo foot_tag();
          exit();
          }if(($script=="html")||($script=="xhtml")){
          $main.="<form action=\"inbox.php?mode=send&amp;id=$id&amp;sid=$sid$chatlink$pass\" method=\"post\">";
          }
          $main.=$center."
          [b]Message:[/b]
          ".getbbcode($inbox[0],$sid,1)."
          
          [b]Forward To:[/b]
          <input name=\"fwd\" maxlength=\"12\"/>
          ";
          if(($script=="html")||($script=="xhtml")){
          $main.="<input type=\"Submit\" value=\"Forward\">$center2</form>";
          }else if($script=="wml"){
          $main.="<anchor>Forward<go href=\"mode=send&amp;id=$id&amp;sid=$sid$chatlink$pass\" method=\"post\">
          <postfield name=\"fwd\" value=\"$(fwd)\"/>
          </go></anchor>$center2";
          }
          $main.=$center;
          $L1="$sixkey<a $key6 href=\"inbox.php?sid=$sid$chatlink$pass\">Inbox</a>";
          $L2="$sevenkey<a $key7 href=\"buds.php?sid=$sid\">BuddyList</a>";
          $L3="$eightkey<a $key8 href=\"chat.php?sid=$sid\">Chat</a>";
          $L4="$ninekey<a $key9 href=\"forums.php?sid=$sid\">Forums</a>";
          $L5="$zerokey<a $key0 href=\"main.php?sid=$sid\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
          $main.=$center2;
          if($script=="html"){echo html($sid,$title,1,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          else if($script=="xhtml"){echo xhtml($sid,$title,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          else if($script=="wml"){echo wml($sid,$title,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          echo foot_tag();
          }
          Code:
          else if(($action=="")&&($mode=="send"))
          {
          addonline(getuid_sid($sid),"Sending Inbox","inbox.php?mode=$mode$chatlink$pass");
          $nick=getnick_sid($sid);
          echo head_tag($nick."@Send Inbox",1,$nick);
          $title="[b]Send Inbox[/b]";
          $main=$center;
          $lastinbox=mysql_fetch_array(mysql_query("SELECT MAX(timesent) FROM inbox WHERE byid=&#39;".getuid_sid($sid)."&#39;"));
          if($lastinbox[0]+msg_antiflood()>time()){
          $rema=$pmfl-$tm;
          $main.="<img src=\"images/notok.gif\" alt=\"x\"/>
          Flood control: ".$lastinbox[0]+msg_antiflood()-time()." Seconds
          ".$center2.$center;
          $L1="$sixkey<a $key6 href=\"inbox.php?sid=$sid$chatlink$pass\">Inbox</a>";
          $L2="$sevenkey<a $key7 href=\"buds.php?sid=$sid\">BuddyList</a>";
          $L3="$eightkey<a $key8 href=\"chat.php?sid=$sid\">Chat</a>";
          $L4="$ninekey<a $key9 href=\"forums.php?sid=$sid\">Forums</a>";
          $L5="$zerokey<a $key0 href=\"main.php?sid=$sid\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
          $main.=$center2;
          if($script=="html"){echo html($sid,$title,1,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          else if($script=="xhtml"){echo xhtml($sid,$title,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          else if($script=="wml"){echo wml($sid,$title,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          echo foot_tag();
          exit();
          }if((ignored(getuid_sid($sid),$who,0)==2)||(ignored(getuid_sid($sid),getuid_nick($fwd),0)==2)){
          $main.="<img src=\"images/notok.gif\" alt=\"x\"/>
          Failed Sending inbox To ".getnick_uid($who)." they hav u on ignore...
          ".$center2.$center;
          $L1="$sixkey<a $key6 href=\"inbox.php?sid=$sid$chatlink$pass\">Inbox</a>";
          $L2="$sevenkey<a $key7 href=\"buds.php?sid=$sid\">BuddyList</a>";
          $L3="$eightkey<a $key8 href=\"chat.php?sid=$sid\">Chat</a>";
          $L4="$ninekey<a $key9 href=\"forums.php?sid=$sid\">Forums</a>";
          $L5="$zerokey<a $key0 href=\"main.php?sid=$sid\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
          $main.=$center2;
          if($script=="html"){echo html($sid,$title,1,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          else if($script=="xhtml"){echo xhtml($sid,$title,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          else if($script=="wml"){echo wml($sid,$title,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          echo foot_tag();
          exit();
          }else if(blocked_site($message,getuid_sid($sid))){
          $bantime=time()+(30*24*60*60);
          $main.="<img src=\"images/notok.gif\" alt=\"X\"/>
          Can&#39;t Send Inbox to ".getnick_uid($who)."
          
          You just sent a link to one of the crapiest sites on earth
           The members of these sites spam here a lot, so go to that site and stay there if you don&#39;t like it here
           as a result of your stupid action:
          1. you have lost your sheild
          2. you have lost all your plusses
          3. You are BANNED!";
          mysql_query("INSERT INTO logs SET action=&#39;autoban&#39;, details=&#39;[b]".getnick_uid(1)."[/b] auto banned ".getnick_uid($who)." for spamming inbox&#39;, date=&#39;".time()."&#39;"); 
          mysql_query("INSERT INTO banned SET uid=&#39;".getuid_sid($sid)."&#39;, penalty=&#39;1&#39;, byid=&#39;1&#39;, remaining=&#39;".$bantime."&#39;, reason=&#39;Banned: Automatic Ban for spamming for a crap site&#39;");
          mysql_query("UPDATE users SET points=&#39;0&#39;, shield=&#39;0&#39; WHERE id=&#39;".getuid_sid($sid)."&#39;");
          mysql_query("INSERT INTO inbox SET text=&#39;[b](forwarded spam via inbox)[/b][br/]".$message."&#39;, byid=&#39;".getuid_sid($sid)."&#39;, toid=&#39;1&#39;, timesent=&#39;".time()."&#39;");
          $main.=$center2;
          if($script=="html"){echo html($sid,$title,1,0,0,0,0,0,0,0,0,0,$main);}
          else if($script=="xhtml"){echo xhtml($sid,$title,0,0,0,0,0,0,0,0,0,$main);}
          else if($script=="wml"){echo wml($sid,$title,0,0,0,0,0,0,0,0,0,$main);}
          echo foot_tag();
          exit();
          }else if(($id!=0)&&(isuser(getuid_nick($fwd)))){
          $inbox=mysql_fetch_array(mysql_query("SELECT text, byid, toid, timesent FROM inbox WHERE id=&#39;".$id."&#39;"));
          mysql_query("INSERT INTO inbox SET text=&#39;".$inbox[0]."&#39;, byid=&#39;".$inbox[1]."&#39;, toid=&#39;".$inbox[2]."&#39;, fwd=&#39;".getuid_nick($fwd)."&#39;, timesent=&#39;".$inbox[3]."&#39;");
          $main.="<img src=\"images/ok.gif\" alt=\"O\"/>
          Inbox Forwarded To $fwd Successfully
          ".$center2.$center;
          $L1="$sixkey<a $key6 href=\"inbox.php?sid=$sid$chatlink$pass\">Inbox</a>";
          $L2="$sevenkey<a $key7 href=\"buds.php?sid=$sid\">BuddyList</a>";
          $L3="$eightkey<a $key8 href=\"chat.php?sid=$sid\">Chat</a>";
          $L4="$ninekey<a $key9 href=\"forums.php?sid=$sid\">Forums</a>";
          $L5="$zerokey<a $key0 href=\"main.php?sid=$sid\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
          $main.=$center2;
          if($script=="html"){echo html($sid,$title,1,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          else if($script=="xhtml"){echo xhtml($sid,$title,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          else if($script=="wml"){echo wml($sid,$title,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          echo foot_tag();
          exit();
          }
          $res=mysql_query("INSERT INTO inbox SET text=&#39;".$message."&#39;, byid=&#39;".getuid_sid($sid)."&#39;, toid=&#39;".$who."&#39;, timesent=&#39;".time()."&#39;");
          if($res){
          $main.="<img src=\"images/ok.gif\" alt=\"O\"/>
          Inbox was sent successfully to ".getnick_uid($who)
          ."
          ".getbbcode($messge,$sid,1);
          }else{
          $main.="<img src=\"images/notok.gif\" alt=\"X\"/>
          Can&#39;t Send Inbox to ".getnick_uid($who)."";
          }
          $link=mysql_fetch_array(mysql_query("SELECT link FROM online WHERE uid=&#39;".getuid_sid($sid)."&#39;"));
          $main.=$center2.$center."
          <a href=\"inbox.php?sid=$sid$chatlink$pass\">Ok!</a>
          
          ";
          if($location=="chat"){$main.="$fivekey<a $key5 href=\"chat.php?action=chat&amp;sid=$sid&amp;rid=$rid$pass\">Back To $rname</a>
          ";}
          $L1="$sixkey<a $key6 href=\"inbox.php?sid=$sid$chatlink$pass\">Inbox</a>";
          $L2="$sevenkey<a $key7 href=\"buds.php?sid=$sid\">BuddyList</a>";
          $L3="$eightkey<a $key8 href=\"chat.php?sid=$sid\">Chat</a>";
          $L4="$ninekey<a $key9 href=\"forums.php?sid=$sid\">Forums</a>";
          $L5="$zerokey<a $key0 href=\"main.php?sid=$sid\"><img src=\"images/home.gif\" alt=\"\"/>Home</a>";
          $main.=$center2;
          if($script=="html"){echo html($sid,$title,1,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          else if($script=="xhtml"){echo xhtml($sid,$title,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          else if($script=="wml"){echo wml($sid,$title,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);}
          echo foot_tag();
          }
          and once again u will most likely only be able to use this as a guide as its from the new script im making which is mostly all from functions and i wont post rest of script if ur smart this will help and as i said in earlier post that i chose hard way of doing the forward option lol

          Comment


            #20
            lol i wont bother quoting you linkrx7, but im just wondering what filenames youve used because it doesnt give any info in that post

            if you just intended it as a (very difficult to follow) guide, then fair enough it doesnt matter too much, just though it would be useful =]

            Comment


              #21
              i dont use inboxproc its all in inbox.php actions are in there and the modes are the bits that are usually in inboxproc didnt see need in making them seperate

              Comment


                #22
                add this into your inbox.php file
                you wanted the steps and here they are ..

                <div class='codetop'>CODE
                <div class='codemain' style='height:200px;white-space:pre;overflow:auto'>else if($action=="fwd")
                {
                addonline(getuid_sid($sid),"Forwarding PM","");
                echo "<card id=\"main\" title=\"Inbox\">";
                echo "<p align=\"center\">";

                $whonick = getnick_uid($who);
                $pmid = $_GET[&#39;pmid&#39;];
                $pmtxt = mysql_fetch_array(mysql_query("SELECT text FROM ibwf_private WHERE id=&#39;".$pmid."&#39;"));
                $fwdmsg = $pmtxt[0];

                echo "Send PM to:

                ";
                echo "User: <input name=\"who\" format=\"*x\" maxlength=\"15\"/>
                ";

                if($fwdmsg !== ""){
                $pmtext = parsepm($fwdmsg, $sid);
                $pmtext = str_replace("/faq","<a href=\"lists.php?action=faqs&sid=$sid\">Users Questions</a>", $pmtext);
                $pmtext = str_replace("/help","<a href=\"help.php?sid=$sid\">Our help menu</a>", $pmtext);
                $pmtext = str_replace("/reader",getnick_uid($pminfo[3]), $pmtext);
                echo $pmtext;
                }else{
                echo "Text: <input name=\"pmtext\" maxlength=\"500\"/>
                ";
                }

                echo "<anchor>SEND<go href=\"inbxproc.php?action=sendto&sid=$sid\" method=\"post\">";
                echo "<postfield name=\"pmtext\" value=\"$(pmtext)\"/>";
                echo "<postfield name=\"pmtou\" value=\"$(who)\"/>";
                echo "</go></anchor>

                ";

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

                echo "Home</a>";
                echo "</p>";
                echo "</card>";
                }</div>

                and add this link to your inbox.php?$action=="readpm"

                Code:
                  echo "<a href=\"inbxproc.php?action=fwd&sid=$sid&pmid=$pmid\">Forward PM</a>";
                i can put it into the files for you, but remember that none of the code here has been tested and i wont be able to test the whole file for you etc ..[/b][/quote]

                nice work i made it activated by some edition coz u told me
                to add this code under $readpm

                Code:
                echo "<a href=\"inbxproc.php?action=fwd&sid=$sid&pmid=$pmid\">Forward PM</a>";
                on the other hand u told me to add ($action=="fwd") inbox.php
                +i needed to add amp; after &

                Comment


                  #23
                  add this into your inbox.php file
                  you wanted the steps and here they are ..

                  <div class='codetop'>CODE
                  <div class='codemain' style='height:200px;white-space:pre;overflow:auto'>else if($action=="fwd")
                  {
                  addonline(getuid_sid($sid),"Forwarding PM","");
                  echo "<card id=\"main\" title=\"Inbox\">";
                  echo "<p align=\"center\">";

                  $whonick = getnick_uid($who);
                  $pmid = $_GET[&#39;pmid&#39;];
                  $pmtxt = mysql_fetch_array(mysql_query("SELECT text FROM ibwf_private WHERE id=&#39;".$pmid."&#39;"));
                  $fwdmsg = $pmtxt[0];

                  echo "Send PM to:

                  ";
                  echo "User: <input name=\"who\" format=\"*x\" maxlength=\"15\"/>
                  ";

                  if($fwdmsg !== ""){
                  $pmtext = parsepm($fwdmsg, $sid);
                  $pmtext = str_replace("/faq","<a href=\"lists.php?action=faqs&sid=$sid\">Users Questions</a>", $pmtext);
                  $pmtext = str_replace("/help","<a href=\"help.php?sid=$sid\">Our help menu</a>", $pmtext);
                  $pmtext = str_replace("/reader",getnick_uid($pminfo[3]), $pmtext);
                  echo $pmtext;
                  }else{
                  echo "Text: <input name=\"pmtext\" maxlength=\"500\"/>
                  ";
                  }

                  echo "<anchor>SEND<go href=\"inbxproc.php?action=sendto&sid=$sid\" method=\"post\">";
                  echo "<postfield name=\"pmtext\" value=\"$(pmtext)\"/>";
                  echo "<postfield name=\"pmtou\" value=\"$(who)\"/>";
                  echo "</go></anchor>

                  ";

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

                  echo "Home</a>";
                  echo "</p>";
                  echo "</card>";
                  }</div>

                  and add this link to your inbox.php?$action=="readpm"

                  Code:
                    echo "<a href=\"inbxproc.php?action=fwd&sid=$sid&pmid=$pmid\">Forward PM</a>";
                  i can put it into the files for you, but remember that none of the code here has been tested and i wont be able to test the whole file for you etc ..[/b][/quote]

                  nice work i made it activated by some edition coz u told me
                  to add this code under $readpm inbox.php

                  Code:
                  echo "<a href=\"inbxproc.php?action=fwd&sid=$sid&pmid=$pmid\">Forward PM</a>";
                  on the other hand u told me to add ($action=="fwd") inbox.php pmpl
                  +i needed to add amp; after &

                  Comment


                    #24
                    i dont use inboxproc its all in inbox.php actions are in there and the modes are the bits that are usually in inboxproc didnt see need in making them seperate[/b]
                    yeah, i think the idea is to keep filesizes down - i mean, inboxproc is a pretty large file on its own, without merging in extra features and inbox.php lol

                    nice work i made it activated by some edition coz u told me
                    to add this code under $readpm

                    Code:
                    echo "<a href=\"inbxproc.php?action=fwd&sid=$sid&pmid=$pmid\">Forward PM</a>";
                    on the other hand u told me to add ($action=="fwd") inbox.php
                    +i needed to add amp; after &[/b]
                    im glad you like it =] BUT its only very simple and there are problems with it like you pointed out with the & &amp; thing (my bad) so please just use it as a starting point and dont rely on it permanently

                    have you managed to get it working yet?

                    Comment


                      #25
                      yeah, i think the idea is to keep filesizes down - i mean, inboxproc is a pretty large file on its own, without merging in extra features and inbox.php lol
                      im glad you like it =] BUT its only very simple and there are problems with it like you pointed out with the & &amp; thing (my bad) so please just use it as a starting point and dont rely on it permanently

                      have you managed to get it working yet?[/b]
                      yeah i managed it,but there is little problem,like when the forwarded pm does nt show to the 1st pm sender name i mean i want it pm by $uid forwarded from $uid

                      plz fix it

                      Comment


                        #26
                        i merged inbox and inboxproc into inbox.php and its only 35kb )

                        Comment


                          #27
                          yeah i managed it,but there is little problem,like when the forwarded pm does nt show to the 1st pm sender name i mean i want it pm by $uid forwarded from $uid

                          plz fix it[/b]
                          erm, maybe ill do it later but ive been really busy later ..
                          how much sql do you know? because if you wanted to doit yourself, all you&#39;d have to do is extract the original sender of the pmid (in the url) then add it into the file

                          i merged inbox and inboxproc into inbox.php and its only 35kb )[/b]
                          lmaoo .. ONLY ..
                          i like my files below 10kb lmao .. that way, its both easier to edit (as long as its all logically split), and safer because if one file leaks out or breaks, its only a small portion of the script ..

                          Comment


                            #28
                            i dont know why are you making simple codes so complicated? its more easier than you think. KWAH thats nice n simple but still u can make it better

                            Comment


                              #29
                              thank you very much!!!!!

                              WapCHAT Forum Currenltly changing over to xhtml

                              My Dowloads Site

                              Comment

                              Working...
                              X