jackpot game

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

    jackpot game

    anyone help me . this from jackpot game its works fine when ppl win but it dosnt deduct the plusses when they lose.
    prob something simple am missing here
    Code:
    if($lucky_number==$random)
            {
                $var   = $bet * 2;
                $nplus = $uplus[0] + $var;
    
                if(mysql_query("UPDATE dave_users SET plusses='".$nplus."' WHERE id='".$uid."'"))
                    echo "<small>You have recieved ".$var." plusses for winning</small>";
                    echo "<br/>";
                    echo "You now have ".$nplus." plusses left.";
                    echo "<br/>";
                }
            }else{
                $nplus = $uplus[0] - $bet;
                if($nplus<0)
                {
                    $nplus = 0;
                }
                if(mysql_query("UPDATE dave_users SET plusses='".$nplus."' WHERE id='".$uid."'"))
                {
                    echo "<small>You have lost ".$bet." plusses for losing</small>";
                    echo "<br/>";
                    echo "You now have ".$nplus." plusses left.";
                    echo "<br/>";
    cheers guys
    Wapchat4u


    Topsites4u

    #2
    this is the version for the wapdesire version 2 i just coded, the old lavalair will follow

    Code:
    <?php
    define('WCS',true);
    include('../core/main.inc');
    header_type();
    cleardata();
    if(ipbanned(ip(),browser())){
    if(!shield(getuid_sid($sid))){
    echo head_tag("Ip Blocked!!!",0,0);
    echo ipbanned_msg();
    echo foot_tag();
    exit();
    }
    }
    if(!islogged($sid)){
    echo head_tag("Error!!!",0,0);
    echo session_expired();
    echo foot_tag();
    exit();
    }
    if(banned(getuid_sid($sid))){
    echo head_tag("Error!!!",1,getnick_sid($sid));
    echo banned_msg($sid);
    echo foot_tag();
    exit();
    }
    mysql_query("UPDATE users SET browser='".browser()."', ipaddress='".ip()."', host='".subno()."' WHERE id='".getuid_sid($sid)."'");
    
    /////////////////////////GAMES/////////////////////////
    
    if($type==spin){
    addonline(getuid_sid($sid),"Games","");
    echo head_tag(getnick_sid($sid)."@Games",1,getnick_sid($sid));
    $title="<b><i>Games</i></b>";
    
    $value = mysql_fetch_array(mysql_query("SELECT points FROM profiles WHERE uid='".getuid_sid($sid)."'"));
            
    $main.="<p align=".align()."><small>Your Points: <b>".$value[0]."</b></small><br/><br/>
    <small>Your lucky number: <b>".$chosen_number."</b></small><br/>
    <small>The winning number: <b>".$random."</b></small>\n";
                
    if($chosen_number==$random){
    
    $reward = $value[0] + $bet_value * 2;
     mysql_query("UPDATE profiles SET points='".$reward."' WHERE uid='".getuid_sid($sid)."'");
    $win = mysql_fetch_array(mysql_query("SELECT points FROM profiles WHERE uid='".getuid_sid($sid)."'"));
    $main.="<br/><small>You have recieved ".$winnings." points for winning<br/><br/>
    You now have ".$win[0]." points left.</small><br/><a href=\"./jackpot.php?&amp;sid=$sid\">Try Again</a>\n";
    }else{
    
    $loose = $value[0] - $bet_value;
    
    mysql_query("UPDATE profiles SET points='".$loose."' WHERE uid='".getuid_sid($sid)."'");
    $lost = mysql_fetch_array(mysql_query("SELECT points FROM profiles WHERE uid='".getuid_sid($sid)."'"));
    $main.="<br/><small>You have lost ".$winnings." points for loosing<br/><br/>
    You now have ".$lost[0]." points left.</small><br/><a href=\"./jackpot.php?&amp;sid=$sid\">Try Again</a>\n";
    }
     $main.="</p>";
      
    $L1="$sixkey<a $key6 href=\"../inbox/inbox.php?sid=$sid\">Inbox</a>";
    $L2="$sevenkey<a $key7 href=\"../buds/buds.php?sid=$sid\">BuddyList</a>";
    $L3="$eightkey<a $key8 href=\"../chat/public.php?sid=$sid\">Chat</a>";
    $L4="$ninekey<a $key9 href=\"../forums/forums.php?sid=$sid\">Forums</a>";
    $L5="$zerokey<a $key0 href=\"../main.php?sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Main Menu</a>";
    echo xhtml($sid,$title,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);
    echo foot_tag();
    mysql_close();
    exit;
    }
    addonline(getuid_sid($sid),"Games","");
    echo head_tag(getnick_sid($sid)."@Games",1,getnick_sid($sid));
    $title="<b><i>Games</i></b>";
    $main="<p align=".align().">
    <img src=\"../phpThumb/phpThumb.php?src=../images/jackpot.gif\" alt=\"!\"/><br/>
    <br/>
    <small>So you want to challenge our dealer and Win the jackpot!</small>
    <br/>
    <small>If you think you got what it takes, click below:</small></p>\n";
    
    $main.="<div class=".align().">
    <form action=\"jackpot.php?type=spin&amp;sid=$sid\" method=\"post\">
    <select name=\"bet_value\">
    <option value=\"10\">10</option>
    <option value=\"20\">20</option>
    <option value=\"30\">30</option>
    <option value=\"40\">40</option>
    <option value=\"50\">50</option>
    <option value=\"60\">60</option>
    <option value=\"70\">70</option>
    <option value=\"80\">80</option>
    <option value=\"90\">90</option>
    <option value=\"100\">100</option>
    </select>
    <br/>
    <small>Choose your lucky number</small>
    <br/>
    <select name=\"chosen_number\">
    <option value=\"1\">1</option>
    <option value=\"2\">2</option>
    <option value=\"3\">3</option>
    <option value=\"4\">4</option>
    <option value=\"5\">5</option>
    <option value=\"6\">6</option>
    <option value=\"7\">7</option>
    <option value=\"8\">8</option>
    <option value=\"9\">9</option>
    <option value=\"10\">10</option>
    </select><br/><br/>
    <input type=\"Submit\" Value=\"Place Bet\"></form></div>\n";
    
    $L1="$sixkey<a $key6 href=\"../inbox/inbox.php?sid=$sid\">Inbox</a>";
    $L2="$sevenkey<a $key7 href=\"../buds/buds.php?sid=$sid\">BuddyList</a>";
    $L3="$eightkey<a $key8 href=\"../chat/public.php?sid=$sid\">Chat</a>";
    $L4="$ninekey<a $key9 href=\"../forums/forums.php?sid=$sid\">Forums</a>";
    $L5="$zerokey<a $key0 href=\"../main.php?sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Main Menu</a>";
    echo xhtml($sid,$title,1,$L1,$L2,$L3,$L4,$L5,0,0,0,$main);
    echo foot_tag();
    mysql_close();
    exit;
    ?>
    Last edited by crazybrumi; 05.09.09, 10:47.
    Want something coded email me at sales@webnwaphost.com for a prices.




    Comment


      #3
      this is the old lava version, i havnt used it on a site yet to see if it error free but i doubt it as all i have done is changed the headers etc to the old versions and the functions

      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();
      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=\"../phpThumb/phpThumb.php?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"];
      $sitename = mysql_fetch_array(mysql_query("SELECT value FROM dave_settings WHERE name='sitename'"));
      $sitename = $sitename[0];
      $uid = getuid_sid($sid);
      $theme = mysql_fetch_array(mysql_query("SELECT theme FROM dave_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();
          }
      }
      ///////////////////////////////////////////////////////////////////////////////////////
      
          if($type==spin){
          
          echo "<head>";
            echo "<title>$nick@$sitename</title>";
            echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\"/>";
            echo "</head>";
            echo "<body>";
          
      
          $value = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE uid='".getuid_sid($sid)."'"));
              
          echo "<p align=".align()."><small>Your Points: <b>".$value[0]."</b></small><br/><br/>
          <small>Your lucky number: <b>".$chosen_number."</b></small><br/>
          <small>The winning number: <b>".$random."</b></small>";
      
                  
          if($chosen_number==$random){
      
          $reward = $value[0] + $bet_value * 2;
      
          mysql_query("UPDATE ibwf_users SET plusses='".$reward."' WHERE uid='".getuid_sid($sid)."'");
          $win = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE uid='".getuid_sid($sid)."'"));
          echo "<br/><small>You have recieved ".$winnings." plusses for winning<br/><br/>
          You now have ".$win[0]." plusses left.</small><br/><a href=\"./jackpot.php?&amp;sid=$sid\">Try Again</a>";
          }else{
      
          $loose = $value[0] - $bet_value;
      
          mysql_query("UPDATE ibwf_users SET plusses='".$loose."' WHERE uid='".getuid_sid($sid)."'");
          $lost = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE uid='".getuid_sid($sid)."'"));
          echo "<br/><small>You have lost ".$winnings." plusses for loosing<br/><br/>
          You now have ".$lost[0]." plusses left.</small><br/><a href=\"./jackpot.php?&amp;sid=$sid\">Try Again</a>";
          }
      
          echo "</p>";
           
          echo "<p align=\"center\">";
          echo "<a href=\"index.php?action=funm&amp;sid=$sid\"><img src=\"../phpThumb/phpThumb.php?src=../images/roll.gif\" alt=\"\"/>Fun Menu</a>";
          echo "<br/>";
          echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"../phpThumb/phpThumb.php?src=../images/home.gif\" alt=\"*\"/>Home</a>";
          echo "</p>";
          echo "</body>";
          echo "</html>";
          exit();
          }
      
      
          if($type==play){
          
          echo "<head>";
            echo "<title>$nick@$sitename</title>";
            echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\"/>";
            echo "</head>";
            echo "<body>";
      
          echo"<p align=\"center\">
          <img src=\"../phpThumb/phpThumb.php?src=../images/jackpot.gif\" alt=\"!\"/><br/>
          <br/><small>So you want to challenge our dealer and Win the jackpot!</small>
          <br/><small>If you think you got what it takes, click below:</small></p>";
      
          echo"<div class=\"center\">
          <form action=\"jackpot.php?type=spin&amp;sid=$sid\" method=\"post\">
          <select name=\"bet_value\">
          <option value=\"10\">10</option>
          <option value=\"20\">20</option>
          <option value=\"30\">30</option>
          <option value=\"40\">40</option>
          <option value=\"50\">50</option>
          <option value=\"60\">60</option>
          <option value=\"70\">70</option>
          <option value=\"80\">80</option>
          <option value=\"90\">90</option>
          <option value=\"100\">100</option>
          </select>
          <br/>
          <small>Choose your lucky number</small>
          <br/>
          <select name=\"chosen_number\">
          <option value=\"1\">1</option>
          <option value=\"2\">2</option>
          <option value=\"3\">3</option>
          <option value=\"4\">4</option>
          <option value=\"5\">5</option>
          <option value=\"6\">6</option>
          <option value=\"7\">7</option>
          <option value=\"8\">8</option>
          <option value=\"9\">9</option>
          <option value=\"10\">10</option>
          </select><br/><br/>
          <input type=\"Submit\" Value=\"Place Bet\"></form></div>";
      
          echo "<p align=\"center\">";
          echo "<a href=\"index.php?action=funm&amp;sid=$sid\"><img src=\"../phpThumb/phpThumb.php?src=../images/roll.gif\" alt=\"\"/>Fun Menu</a>";
          echo "<br/>";
          echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"../phpThumb/phpThumb.php?src=../images/home.gif\" alt=\"*\"/>Home</a>";
          echo "</p>";
          echo "</body>";
          echo "</html>";
          exit();
      
          }
      
          echo "<head>";
            echo "<title>$nick@$sitename</title>";
            echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\"/>";
            echo "</head>";
            echo "<body>";
      
          echo "<p align=\"center\"><img src=\"../phpThumb/phpThumb.php?src=../images/jackpot.gif\" alt=\"!\"/><br/>";
          echo "<br/><small>So you want to challenge our dealer and Win the jackpot!</small><br/>";
          echo "<small>If you think you got what it takes, click below:</small><br/>";
          echo "<small><a href=\"jackpot.php?type=play&amp;sid=$sid\">Play Now</a></small></p>";
      
          echo "<p align=\"center\">";
          echo "<a href=\"index.php?action=funm&amp;sid=$sid\"><img src=\"../phpThumb/phpThumb.php?src=../images/roll.gif\" alt=\"\"/>*</a>";
          echo "Fun Menu</a></small>";
          echo "<br/>";
          echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"../phpThumb/phpThumb.php?src=../images/home.gif\" alt=\"*\"/>";
          echo "Home</a></small>";
          echo "</p>";
          echo "</body>";
          echo "</html>";
          exit();
      
      ?>
      Want something coded email me at sales@webnwaphost.com for a prices.




      Comment


        #4
        Code:
        <?php
        
        /**
        * @Copyright wizard <mc_jayrulez@yahoo.com.au>
        * @File: jackpot.php
        * @param: $sid
        */
        
        header('Content-type: text/vnd.wap.wml');
        
        echo '<?xml version="1.0" encoding="utf-8"?>';
        echo '<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapforum.org/DTD/wml_1.1.xml">';
        
        echo '<wml>';
        
        include("config.php");
        
        include("core.php");
        
        function canplay_jackpot($uid)
        {
            $sql = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'"));
            if($sql[0]>=10)
            {
                return true;
            }else{
                false;
            }
        }
        
        $bcon   = connectdb();
        $sid    = $_GET['sid'];
        $uid    = getuid_sid($sid);
        $action = $_GET['action'];
        
        if(!$bcon)
        {
            echo '<card id="main" title="Database Error">';
            echo '<p align="center">';
            echo '<img src="images/notok.gif" alt="X"/>';
            echo '<br/>';
            echo '<small>Database Connection Error, please try again later!</small>';
            echo '</p>';
            echo '<p align="center">';
            echo '<small><a href="index.php?action=funm&amp;sid='.$sid.'"><img src="images/roll.gif" alt="*"/>';
            echo 'Fun Menu</a></small>';
            echo '<br/>';
            echo '<small><a href="index.php?action=main&amp;sid='.$sid.'"><img src="images/home.gif" alt="*"/>';
            echo 'Home</a></small>';
            echo '</p>';
            echo '</card>';
            echo '</wml>';
            exit();
        }
        
        if(!islogged($sid))
        {
            echo '<card id="main" title="Login Error">';
            echo '<p align="center">';
            echo '<img src="images/notok.gif" alt="X"/>';
            echo '<br/>';
            echo '<small>You are not logged in or your session has expired!</small>';
            echo '<br/>';
            echo '<small><a href="login.php">Login</a></small>';
            echo '</p>';
            echo '<p align="center">';
            echo '<small><a href="index.php?action=main&amp;sid='.$sid.'"><img src="images/home.gif" alt="*"/>';
            echo 'Home</a></small>';
            echo '</p>';
            echo '</card>';
            echo '</wml>';
            exit();
        }
        
        if(isbanned($uid))
        {
            echo '<card id="main" title="Login Error">';
            echo '<p align="center">';
            echo '<img src="images/notok.gif" alt="X"/>';
            echo '<br/>';
            echo '<small>';
            echo '<b>You are Banned</b><br/>';
            echo '<br/>';
            $sql    = "SELECT timeto, pnreas, exid 
                       FROM ibwf_parusa 
                       WHERE uid='".$uid."' 
                       AND penalty='1' OR uid='".$uid."' 
                       AND penalty='2'
                      ";
            $banto  = mysql_fetch_array(mysql_query($sql));
            $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.'';
            echo '<br/>';
            $nick = getnick_uid($banto[2]);
            echo '<b>By: </b>'.$nick.'';
            echo '<br/>';
            echo '<b>Reason: </b>'.$banto[1].'';
            echo '</small>';
            echo '</p>';
            echo '<p align="center">';
            echo '<small><a href="index.php?action=main&amp;sid='.$sid.'"><img src="images/home.gif" alt="*"/>';
            echo 'Home</a></small>';
            echo '</p>';
            echo '</card>';
            echo '</wml>';
            exit();
        }
        
        if(!canplay_jackpot($uid))
        {
            echo '<card id="main" title="Error">';
            echo '<p align="center">';
            echo '<img src="images/notok.gif" alt="X"/>';
            echo '<br/>';
            echo '<small>You must have atleast 10 plusses to play JackPot!</small>';
            echo '<br/>';
            echo '</p>';
            echo '<p align="center">';
            echo '<small><a href="index.php?action=funm&amp;sid='.$sid.'"><img src="images/roll.gif" alt="*"/>';
            echo 'Fun Menu</a></small>';
            echo '<br/>';
            echo '<small><a href="index.php?action=main&amp;sid='.$sid.'"><img src="images/home.gif" alt="*"/>';
            echo 'Home</a></small>';
            echo '</p>';
            echo '</card>';
            echo '</wml>';
            exit();
        }
        
        if($action=='play')
        {
            echo '<card id="main" title="JackPot">';
            echo '<p align="center">';
            echo '<img src="images/jackpot.gif" alt="*"/>';
            echo '<br/>';
            echo '<small>Place your bet</small>';
            echo '<br/>';
            echo '<select name="bet">';
            echo '<option value="10">10</option>';
            echo '<option value="20">20</option>';
            echo '<option value="30">30</option>';
            echo '<option value="40">40</option>';
            echo '<option value="50">50</option>';
            echo '<option value="60">60</option>';
            echo '<option value="70">70</option>';
            echo '<option value="80">80</option>';
            echo '<option value="90">90</option>';
            echo '<option value="100">100</option>';
            echo '</select>';
            echo '<br/>';
            echo '<small>Choose your lucky number</small>';
            echo '<br/>';
            echo '<select name="lucky_number">';
            echo '<option value="1">1</option>';
            echo '<option value="2">2</option>';
            echo '<option value="3">3</option>';
            echo '<option value="4">4</option>';
            echo '<option value="5">5</option>';
            echo '<option value="6">6</option>';
            echo '<option value="7">7</option>';
            echo '<option value="8">8</option>';
            echo '<option value="9">9</option>';
            echo '<option value="10">10</option>';
            echo '</select>';
            echo '<br/>';
            echo '<anchor>[Spin]<go href="jackpot.php?action=do_bet&amp;sid='.$sid.'" method="post">';
            echo '<postfield name="bet" value="$(bet)"/>';
            echo '<postfield name="lucky_number" value="$(lucky_number)"/>';
            echo '</go></anchor>';
            echo '</p>';
            echo '<p align="center">';
            echo '<small><a href="index.php?action=funm&amp;sid='.$sid.'"><img src="images/roll.gif" alt="*"/>';
            echo 'Fun Menu</a></small>';
            echo '<br/>';
            echo '<small><a href="index.php?action=main&amp;sid='.$sid.'"><img src="images/home.gif" alt="*"/>';
            echo 'Home</a></small>';
            echo '</p>';
            echo '</card>';
        }else if($action=='do_bet')
        {
            if(isset($_POST))
            {
                $bet          = $_POST['bet'];
                $lucky_number = $_POST['lucky_number'];
                $random = rand(1,10);
        
                echo '<card id="main" title="JackPot">';
                echo '<p align="center">';
                echo '<img src="images/jackpot.gif" alt="*"/>';
                echo '<br/>';
                echo '<small>JackPot Result</small>';
                echo '<br/>';
                echo '<br/>';
                
                $uplus = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'"));
                
                echo '<small>Your Plusses: <b>'.$uplus[0].'</b></small>';
                echo '<br/>';
                echo '<br/>';
                echo '<small>Your lucky number: <b>'.$lucky_number.'</b></small>';
                echo '<br/>';
                echo '<small>The winning number: <b>'.$random.'</b></small>';
                echo '<br/>';
                echo '<br/>';
                    
                if($lucky_number==$random)
                {
                    $var   = $bet * 2;
                    $nplus = $uplus[0] + $var;
        
                    if(@mysql_query("UPDATE ibwf_users SET plusses='".$nplus."' WHERE id='".$uid."'"))
                    {
                        echo '<small>You have recieved '.$var.' plusses for winning</small>';
                        echo '<br/>';
                        echo 'You now have '.$nplus.' plusses left.';
                        echo '<br/>';
                    }
                }else{
                    $nplus = $uplus[0] - $bet;
                    if($nplus<0)
                    {
                        $nplus = 0;
                    }
                    if(@mysql_query("UPDATE ibwf_users SET plusses='".$nplus."' WHERE id='".$uid."'"))
                    {
                        echo '<small>You have lost '.$bet.' plusses for losing</small>';
                        echo '<br/>';
                        echo 'You now have '.$nplus.' plusses left.';
                        echo '<br/>';
                    }
                }
                echo '<br/>';
                echo '<small><a href="jackpot.php?action=play&amp;sid='.$sid.'">Try Again</a></small>';
                
                echo '</p>';
                echo '<p align="center">';
                echo '<small><a href="index.php?action=funm&amp;sid='.$sid.'"><img src="images/roll.gif" alt="*"/>';
                echo 'Fun Menu</a></small><br/>';
                echo '<small><a href="index.php?action=main&amp;sid='.$sid.'"><img src="images/home.gif" alt="*"/>';
                echo 'Home</a></small>';
                echo '</p>';
                echo '</card>';
            }else{
                echo '<card id="main" title="Cheater">';
                echo '<p align="center">';
                echo '<small>What the hell are you trying???</small><br/>';
                echo '</p>';
                echo '<p align="center">';
                echo '<small><a href="index.php?action=funm&amp;sid='.$sid.'"><img src="images/roll.gif" alt="*"/>';
                echo 'Fun Menu</a></small>';
                echo '<br/>';
                echo '<small><a href="index.php?action=main&amp;sid='.$sid.'"><img src="images/home.gif" alt="*"/>';
                echo 'Home</a></small>';
                echo '</p>';
                echo '</card>';
            }
        }else{
            echo '<card id="main" title="JackPot">';
            echo '<p align="center">';
            echo '<img src="images/jackpot.gif" alt="*"/>';
            echo '<br/>';
            echo '<small>So you want to challenge our dealer and Win the jackpot!</small>';
            echo '<br/>';
            echo '<small>If you think you got what it takes, click below:</small>';
            echo '<br/>';
            echo '<small><a href="jackpot.php?action=play&amp;sid='.$sid.'">Play Now</a></small>';
            echo '</p>';
            echo '<p align="center">';
            echo '<small><a href="index.php?action=funm&amp;sid='.$sid.'"><img src="images/roll.gif" alt="*"/>';
            echo 'Fun Menu</a></small>';
            echo '<br/>';
            echo '<small><a href="index.php?action=main&amp;sid='.$sid.'"><img src="images/home.gif" alt="*"/>';
            echo 'Home</a></small>';
            echo '</p>';
            echo '</card>';
        }
        
        echo '</wml>';
        
        ?>

        Comment


          #5
          heres my working copy
          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();
          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=\"../phpThumb/phpThumb.php?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"];
          $sitename = mysql_fetch_array(mysql_query("SELECT value FROM dave_settings WHERE name='sitename'"));
          $sitename = $sitename[0];
          $uid = getuid_sid($sid);
          $theme = mysql_fetch_array(mysql_query("SELECT theme FROM dave_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();
              }
          }
          ///////////////////////////////////////////////////////////////////////////////////////
          
              if($type==spin)
          {
          
          if(isset($_POST))
              
                  $bet_value          = $_POST["bet_value"];
                  $chosen_number = $_POST["chosen_number"];
                  $random = rand(1,10);
          
          
              
              echo "<head>";
                echo "<title>$nick@$sitename</title>";
                echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\"/>";
                echo "</head>";
                echo "<body>";
              
          
              $value = mysql_fetch_array(mysql_query("SELECT plusses FROM dave_users WHERE id='".$uid."'"));
                  
              echo "<p align=\"center\"><small>Your Points: <b>".$value[0]."</b></small><br/><br/>
              <small>Your lucky number: <b>".$chosen_number."</b></small><br/>
              <small>The winning number: <b>".$random."</b></small>";
          
                      
              if($chosen_number==$random){
          
              $reward = $value[0] + $bet_value * 2;
          
              mysql_query("UPDATE dave_users SET plusses='".$reward."' WHERE id='".$uid."'");
              $win = mysql_fetch_array(mysql_query("SELECT plusses FROM dave_users WHERE id='".$uid."'"));
              echo "<br/><small>You have recieved ".$winnings." plusses for winning<br/><br/>
              You now have ".$win[0]." plusses left.</small><br/><a href=\"./jackpot.php?&amp;sid=$sid\">Try Again</a>";
              }else{
          
              $loose = $value[0] - $bet_value;
          
              mysql_query("UPDATE dave_users SET plusses='".$loose."' WHERE id='".$uid."'");
              $lost = mysql_fetch_array(mysql_query("SELECT plusses FROM dave_users WHERE id='".$uid."'"));
              echo "<br/><small>You have lost ".$winnings." plusses for loosing<br/><br/>
              You now have ".$lost[0]." plusses left.</small><br/><a href=\"./jackpot.php?&amp;sid=$sid\">Try Again</a>";
              }
          
              echo "</p>";
               
              echo "<p align=\"center\">";
              echo "<a href=\"index.php?action=funm&amp;sid=$sid\"><img src=\"../phpThumb/phpThumb.php?src=../images/roll.gif\" alt=\"\"/>Fun Menu</a>";
              echo "<br/>";
              echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"../phpThumb/phpThumb.php?src=../images/home.gif\" alt=\"*\"/>Home</a>";
              echo "</p>";
              echo "</body>";
              echo "</html>";
              exit();
              }
          
          
              if($type==play){
              
              echo "<head>";
                echo "<title>$nick@$sitename</title>";
                echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\"/>";
                echo "</head>";
                echo "<body>";
          
              echo"<p align=\"center\">
              <img src=\"../phpThumb/phpThumb.php?src=../images/jackpot.gif\" alt=\"!\"/><br/>
              <br/><small>So you want to challenge our dealer and Win the jackpot!</small>
              <br/><small>If you think you got what it takes, click below:</small></p>";
          
              echo"<div class=\"center\">
              <form action=\"jackpot.php?type=spin&amp;sid=$sid\" method=\"post\">
              <select name=\"bet_value\">
              <option value=\"10\">10</option>
              <option value=\"20\">20</option>
              <option value=\"30\">30</option>
              <option value=\"40\">40</option>
              <option value=\"50\">50</option>
              <option value=\"60\">60</option>
              <option value=\"70\">70</option>
              <option value=\"80\">80</option>
              <option value=\"90\">90</option>
              <option value=\"100\">100</option>
              </select>
              <br/>
              <small>Choose your lucky number</small>
              <br/>
              <select name=\"chosen_number\">
              <option value=\"1\">1</option>
              <option value=\"2\">2</option>
              <option value=\"3\">3</option>
              <option value=\"4\">4</option>
              <option value=\"5\">5</option>
              <option value=\"6\">6</option>
              <option value=\"7\">7</option>
              <option value=\"8\">8</option>
              <option value=\"9\">9</option>
              <option value=\"10\">10</option>
              </select><br/><br/>
              <input type=\"Submit\" Value=\"Place Bet\"></form></div>";
          
              echo "<p align=\"center\">";
              echo "<a href=\"index.php?action=funm&amp;sid=$sid\"><img src=\"../phpThumb/phpThumb.php?src=../images/roll.gif\" alt=\"\"/>Fun Menu</a>";
              echo "<br/>";
              echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"../phpThumb/phpThumb.php?src=../images/home.gif\" alt=\"*\"/>Home</a>";
              echo "</p>";
              echo "</body>";
              echo "</html>";
              exit();
          }
              
          
              echo "<head>";
                echo "<title>$nick@$sitename</title>";
                echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\"/>";
                echo "</head>";
                echo "<body>";
          
              echo "<p align=\"center\"><img src=\"../phpThumb/phpThumb.php?src=../images/jackpot.gif\" alt=\"!\"/><br/>";
              echo "<br/><small>So you want to challenge our dealer and Win the jackpot!</small><br/>";
              echo "<small>If you think you got what it takes, click below:</small><br/>";
              echo "<small><a href=\"jackpot.php?type=play&amp;sid=$sid\">Play Now</a></small></p>";
          
              echo "<p align=\"center\">";
              echo "<a href=\"index.php?action=funm&amp;sid=$sid\"><img src=\"../phpThumb/phpThumb.php?src=../images/roll.gif\" alt=\"\"/>*</a>";
              echo "Fun Menu</a></small>";
              echo "<br/>";
              echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"../phpThumb/phpThumb.php?src=../images/home.gif\" alt=\"*\"/>";
              echo "Home</a></small>";
              echo "</p>";
              echo "</body>";
              echo "</html>";
              exit();
          
          ?>
          works for me lol .
          Wapchat4u


          Topsites4u

          Comment


            #6
            theres no point of usings isset.
            Want something coded email me at sales@webnwaphost.com for a prices.




            Comment

            Working...
            X