ghost inbox from shop wapdesire

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

    ghost inbox from shop wapdesire

    hi folks this is shop.php page
    in wapdesire
    PHP Code:
    <?php
    include("config.php");
    include(
    "core.php");
    header("Cache-Control: no-cache, must-revalidate");
    header("Pragma: no-cache");
    //header('Content-type: application/vnd.wap.xhtml+xml'); 
    echo "<?xml version=\"1.0\"?>";
    echo 
    "<!DOCTYPE html PUBLIC \"-//WAPFORUM//DTD XHTML Mobile 1.0//EN\" \"http://www.wapforum.org/DTD/xhtml-mobile10.dtd\">";
    ?>
    <html xmlns="http://www.w3.org/1999/xhtml">
    <?php
    $bcon 
    connectdb();
    $sitename mysql_fetch_array(mysql_query("SELECT value FROM ibwf_settings WHERE name='sitename'"));
    $sitename $sitename[0];

    if (!
    $bcon)
    {
        echo 
    "<head>";
        echo 
    "<title>Error!!!</title>";
        echo 
    "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/white_medium.css\">";
        echo 
    "</head>";
        echo 
    "<body>";
        echo 
    "<p align=\"center\">";
        echo 
    "<img src=\"../images/notok.gif\" alt=\"!\"/><br/>";
        echo 
    "<b><strong>Error! Cannot Connect To Database...</strong></b><br/><br/>";
        echo 
    "This error happens usually when backing up the database, please be patient...";
        echo 
    "</p>";
        echo 
    "</body>";
        echo 
    "</html>";
        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);
    $theme mysql_fetch_array(mysql_query("SELECT theme FROM ibwf_users WHERE id='".$uid."'"));
    cleardata();

    if((
    $action != "") && ($action!="terms"))
    {
        
    $uid getuid_sid($sid);
        if((
    islogged($sid)==false)||($uid==0))
        {
          echo 
    "<head>";
          echo 
    "<title>Error!!!</title>";
          echo 
    "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/white_medium.css\">";
          echo 
    "</head>";
          echo 
    "<body>";
          echo 
    "<p align=\"center\">";
          echo 
    "You are not logged in<br/>";
          echo 
    "Or Your session has been expired<br/><br/>";
          echo 
    "<a href=\"index.php\">Login</a>";
          echo 
    "</p>";
          echo 
    "</body>";
          echo 
    "</html>";
          exit();
        } 
    }
    //echo isbanned($uid);
    if(isbanned($uid))
        {
          echo 
    "<head>";
          echo 
    "<title>Error!!!</title>";
          echo 
    "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
          echo 
    "</head>";
          echo 
    "<body>";
          echo 
    "<p align=\"center\">";
          echo 
    "<img src=\"../images/notok.gif\" alt=\"x\"/><br/>";
          echo 
    "<b>You are Banned</b><br/><br/>";
          
    $banto mysql_fetch_array(mysql_query("SELECT timeto, pnreas, exid FROM ibwf_penalties WHERE uid='".$uid."' AND penalty='1' OR uid='".$uid."' AND penalty='2'"));
        
    $banres mysql_fetch_array(mysql_query("SELECT lastpnreas FROM ibwf_users WHERE id='".$uid."'"));
          
    $remain $banto[0]- time();
          
    $rmsg gettimemsg($remain);
          echo 
    "<b>Time Left: </b>$rmsg<br/>";
          
    $nick getnick_uid($banto[2]);
        echo 
    "<b>By: </b>$nick<br/>";
        echo 
    "<b>Reason: </b>$banto[1]";
          
    //echo "<a href=\"index.php\">Login</a>";
          
    echo "</p>";
          echo 
    "</body>";
          echo 
    "</html>";
          exit();
        }
    $res mysql_query("UPDATE ibwf_users SET browserm='".$brws4."', ipadd='".$uip."' WHERE id='".getuid_sid($sid)."'");

    ////////////////////////////////////////MAIN PAGE
    if($action=="shop")
    {
      
    addvisitor();
      
    addonline(getuid_sid($sid),"Shop","");
      
    //saveuinfo($sid);
      
      
    echo "<head>";
      echo 
    "<title>Shop</title>";
      echo 
    "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
      echo 
    "</head>";
      echo 
    "<body>";
      echo 
    "<p align=\"center\">";
      
    $plusses mysql_fetch_array(mysql_query("SELECT plusses, name FROM ibwf_users WHERE id='".$uid."'"));
      Echo 
    "Welcome To The Plusses Shop, Here You Can Spend Your Hard Earned Plusses To Get Special Features On Site<br/>";
      echo 
    "You Currently Have $plusses[0] Plusses";
      echo 
    "</p>";
      echo 
    "<p align=\"center\">";
      echo 
    "The Items You Can Buy Are Listed Below:</p>";
        
      echo 
    "<p align=\"center\">";
        echo 
    "Your Own Personal Avatar<br/>";
        echo 
    "Cost: 1000 Plusses<br/>";
        echo 
    "<b>1 </b><a accesskey=\"1\" href=\"shop.php?action=peravat&amp;sid=$sid&amp;who=$plusses[1]&amp;whoid=$uid\">Buy Now</a>";
        echo 
    "</p>";    
        
      echo 
    "<p align=\"center\">";
        echo 
    "Your Own Personal Smilie<br/>";
        echo 
    "Cost: 2000 Plusses<br/>";
        echo 
    "<b>2 </b><a accesskey=\"2\" href=\"shop.php?action=persmile&amp;sid=$sid&amp;who=$plusses[1]&amp;whoid=$uid\">Buy Now</a>";
        echo 
    "</p>";    
        
      echo 
    "<p align=\"center\">";
        echo 
    "Your Own Public Chatroom<br/>";
        echo 
    "Cost: 4000 Plusses<br/>";
        echo 
    "<b>3 </b><a accesskey=\"3\" href=\"shop.php?action=pubchat&amp;sid=$sid&amp;who=$plusses[1]&amp;whoid=$uid\">Buy Now</a>";
        echo 
    "</p>";
        
      echo 
    "<p align=\"center\">";
        echo 
    "Your Own Forum<br/>";
        echo 
    "Cost: 5000 Plusses<br/>";
        echo 
    "<b>4 </b><a accesskey=\"4\" href=\"shop.php?action=pubforum&amp;sid=$sid&amp;who=$plusses[1]&amp;whoid=$uid\">Buy Now</a>";
        echo 
    "</p>";
    /*    
      echo "<p align=\"center\">";
       echo "Your Own Status<br/>";
        echo "Cost: 900 Plusses<br/>";
        echo "<b>5 </b><a accesskey=\"5\" href=\"shop.php?action=perstaus?sid=$sid\">Buy Now";
        echo "</p>";
    */
        
      
    echo "<p align=\"center\">";

      echo 
    "<b>0 </b><a accesskey=\"0\" href=\"index.php?action=main&amp;sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>";
      echo 
    "</p>";
      echo 
    "</body>";
    }
    else if(
    $action=="peravat")
    {
      echo 
    "<head>";
      echo 
    "<title>Shop</title>";
      echo 
    "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
      echo 
    "</head>";
      echo 
    "<body>";
        echo 
    "<p align=\"center\">";
        
    $ownid[0]=1;
         
    $who=$_GET["whoid"];
        
    $whoid=$_GET["who"];
        
    $plusses mysql_fetch_array(mysql_query("SELECT plusses, name FROM ibwf_users WHERE id='".$who."'"));
        
    $remainplus $plusses[0] - 1000;
        
    $plussupdate mysql_query("UPDATE ibwf_users SET plusses='".$remainplus."' WHERE id='".$who."'");
        
    $message "A User Has visited The Plusses Shop and Ordered a Personal Avatar, the user is ".$whoid." Please Action This request as soon as possible.[br/][small][i]p.s: this is an automated pm[/i][/small]";
        
    autopm($message$ownid[0]);
        echo 
    "Thank You For Choosing To Purchase Your Personal Avatar. Your Plusses Have Been Debited and your request sent to the staff for processing.<br/>";
        echo 
    "We Expect your personal avatar to be ready in 48hours or less<br/>";
        echo 
    "You Now have $remainplus Plusses Remaining<br/></p>";
        echo 
    "<p align=\"center\">";
      echo 
    "<b>0 </b><a accesskey=\"0\" href=\"index.php?action=main&amp;sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>";
      echo 
    "</p>";
        echo 
    "</body>";
    }
    else if(
    $action=="persmile")
    {
      echo 
    "<head>";
      echo 
    "<title>Shop</title>";
      echo 
    "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
      echo 
    "</head>";
      echo 
    "<body>";
        echo 
    "<p align=\"center\">";
        
    $ownid[0]=1;
        
    $who=$_GET["whoid"];
        
    $whoid=$_GET["who"];
        
    $plusses mysql_fetch_array(mysql_query("SELECT plusses, name FROM ibwf_users WHERE id='".$who."'"));
        
    $remainplus $plusses[0] - 2000;
        
    $plussupdate mysql_query("UPDATE ibwf_users SET plusses='".$remainplus."' WHERE id='".$who."'");
        
    $message "A User Has visited The Plusses Shop and Ordered a Personal Smilie, the user is ".$whoid." Please Action This request as soon as possible.[br/][small][i]p.s: this is an automated pm[/i][/small]";
        
    autopm($message$ownid[0]);
        echo 
    "Thank You For Choosing To Purchase Your Personal Smilie. Your Plusses Have Been Debited and your request sent to the staff for processing.<br/>";
        echo 
    "We Expect your Personal Smilie to be ready in 48hours or less<br/>";
        echo 
    "You Now have $remainplus Plusses Remaining<br/></p>";
        echo 
    "<p align=\"center\">";
      echo 
    "<b>0 </b><a accesskey=\"0\" href=\"index.php?action=main&amp;sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>";
      echo 
    "</p>";
        echo 
    "</body>";
    }
    else if(
    $action=="pubchat")
    {
      echo 
    "<head>";
      echo 
    "<title>Shop</title>";
      echo 
    "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
      echo 
    "</head>";
      echo 
    "<body>";
        echo 
    "<p align=\"center\">";
        
    $ownid[0]=1;
        
    $who=$_GET["whoid"];
        
    $whoid=$_GET["who"];
        
    $plusses mysql_fetch_array(mysql_query("SELECT plusses, name FROM ibwf_users WHERE id='".$who."'"));
        
    $remainplus $plusses[0] - 4000;
        
    $plussupdate mysql_query("UPDATE ibwf_users SET plusses='".$remainplus."' WHERE id='".$who."'");
        
    $message "A User Has visited The Plusses Shop and Ordered a Public Chatroom, the user is ".$whoid." Please Action This request as soon as possible.[br/][small][i]p.s: this is an automated pm[/i][/small]";
        
    autopm($message$ownid[0]);
        echo 
    "Thank You For Choosing To Purchase Your Own Chatroom. Your Plusses Have Been Debited and your request sent to the staff for processing.<br/>";
        echo 
    "We Expect your Room to be live within 48hours or less<br/>";
        echo 
    "You Now have $remainplus Plusses Remaining<br/></p>";

        echo 
    "<p align=\"center\">";
      echo 
    "<b>0 </b><a accesskey=\"0\" href=\"index.php?action=main&amp;sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>";
      echo 
    "</p>";
        echo 
    "</body>";
    }
    else if(
    $action=="pubforum")
    {
      echo 
    "<head>";
      echo 
    "<title>Shop</title>";
      echo 
    "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
      echo 
    "</head>";
      echo 
    "<body>";
        echo 
    "<p align=\"center\">";
        
    $ownid[0]=1;
        
    $who=$_GET["whoid"];
        
    $whoid=$_GET["who"];
        
    $plusses mysql_fetch_array(mysql_query("SELECT plusses, name FROM ibwf_users WHERE id='".$who."'"));
        
    $remainplus $plusses[0] - 5000;
        
    $plussupdate mysql_query("UPDATE ibwf_users SET plusses='".$remainplus."' WHERE id='".$who."'");
        
    $message "A User Has visited The Plusses Shop and Ordered a Public Forum, the user is ".$whoid." Please Action This request as soon as possible.[br/][small][i]p.s: this is an automated pm[/i][/small]";
        
    autopm($message$ownid[0]);
        echo 
    "Thank You For Choosing To Purchase a Public Forum. Your Plusses Have Been Debited and your request sent to the staff for processing.<br/>";
        echo 
    "We Expect your forum will be live within 48hours or less<br/>";
        echo 
    "You Now have $remainplus Plusses Remaining<br/></p>";

        echo 
    "<p align=\"center\">";
      echo 
    "<b>0 </b><a accesskey=\"0\" href=\"index.php?action=main&amp;sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>";
      echo 
    "</p>";
        echo 
    "</body>";
    }
    ?>
    </html>
    there's a bug on it..when
    a user, for exemple, buy a personal avatar,
    the automatic message to owner gets on
    database but it shows on owner's inbox page
    as a ghost message!..
    you find alert 'bout new message but when you open the inbox page
    you don't see nothin'
    someone can help me to fix this
    sigpicthe italian/international COMMUNITY of friendship
    http://people2000.netne.net
    WAP/WEB
    peoplemailbox@katamail.com

    #2
    $ownid[0]=1;

    your id should be set to 1 in your users database to fix that ghost inbox









    Dont Ask Me Dumb Questions.Or you'l get a Dumb Answer..
    Want A Profesional Logo or Theme For Your wap site Pm Me.If I Have The Time Ill Make It For Free

    Comment


      #3
      thanks..my id was different..now i've understood why
      it didn't work
      i have changed into 1 and now everything works fine..

      strange things happen..old messages went into my inbox..after i changed my id to 1 but
      now if some user buy something, new message don't show again!!..i don't understand why..
      i think about another way..
      is i possible to send the messages to my nickname
      instead that my id?
      changing
      $ownid[0]=1;
      in something
      to my nick?
      Last edited by honkytonkman; 07.07.09, 15:08.
      sigpicthe italian/international COMMUNITY of friendship
      http://people2000.netne.net
      WAP/WEB
      peoplemailbox@katamail.com

      Comment

      Working...
      X