Jump to content

Changing Layouts


corkg

Recommended Posts

I have some code and it is for a roulette wheel, when you open the page in IE the layout is wrong, when you win the layout goes wrong, yet for some reason when you lose the layout looks like it is suppose to, i have removed some of the code if you need more just ask please help.

 

Why does it do this?

 


$yougot = $nmoney - $bet;






if ($yougot <= 0){

$lala = $usersmoney - $bet;
$ownersmoney = $ownersmoney1 + $bet;
mysql_query("UPDATE users SET money='$ownersmoney' WHERE username='$owner'");
mysql_query("UPDATE users SET money='$lala' WHERE username='$username'");
$new_money = $bet * $win;
$ear = $Roulette->profit + $bet;
mysql_query("UPDATE casinos SET profit='$ear' WHERE location='$fetch->location' AND casino='Roulette'");
?>
<div align='center'>
  <table width=30% cellpadding=2 cellspacing=0>
    <tr>
      <td align=center><strong>The Winning Wheel Number was <?php echo "$number"; ?></strong></td>
    </tr>
    <tr>
      <td>Unlucky, you lost £<? echo" $bet"; ?>
        <?
}elseif ($yougot > 0){
?>
      </td>
    </tr>
  </table>
</div>
<div align="center">
  <table width=30% align="center" cellpadding=2 cellspacing=0>
    <tr >
      <td height="23" align=center >Wheel Number <?php echo "$number"; ?> Won!</td>
    </tr>
    <tr>
      <td><div align="center">Congratulations you won £<? echo" $nmoney"; ?> </div></td>
    </tr>
    <tr>
      <td><?


if ($nmoney > $ownersmoney1){
$lost ='1';
$ownersmoney = $money1;


}elseif ($nmoney <= $ownersmoney1){
$lost = '0';


}
if ($lost == '1'){
$lala = $usersmoney + $bet;
$ownersmoney = $ownersmoney1 - $nmoney;
echo "The owner of the table is bankrupt there is no more money to pay out.";
mysql_query("UPDATE users SET money='$lala' WHERE username='$username'");
mysql_query("UPDATE users SET money='0' WHERE username='$owner'");


}elseif ($lost == '0'){
$ownersmoney = $ownersmoney1 - $nmoney;
$winermoney = $usersmoney + $nmoney;
mysql_query("UPDATE users SET money='$ownersmoney' WHERE username='$owner'");
mysql_query("UPDATE users SET money='$winermoney' WHERE username='$username'");
$ear = $Roulette->profit - $bet;
mysql_query("UPDATE casinos SET profit='$ear' WHERE location='$fetch->location' AND casino='Roulette'");
echo "";
}
}
}
}}}}

?>  

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.