Fork me on GitHub

3585 bytes of ActionScript

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161

<div>
<div class="s-bk-lf">
	<div class="acc-title">Yaz? Tura</div> 
</div>


<div class="silver-bk">
<div class="clr"></div>	
<?PHP
$_OPTIMIZATION["title"] = "Hesap - Gunluk Bonus";
$usid = $_SESSION["user_id"];
$uname = $_SESSION["user"];
$db->Query("SELECT * FROM db_users_b WHERE id = '$usid' LIMIT 1");
$user_data = $db->FetchArray();
if (isset($_POST['stavka'])) {
$naper = intval($_POST['naper']);
$stavka = intval($_POST['stavka']);
$nap = rand(1,3);
$time = time();
		if($stavka <= $user_data['money_b']) {
			if($stavka >= 10) {
				if($naper == 1 or $naper ==  2 or $naper ==  3) {
					if($naper == $nap) {
					$sum = $stavka * 1.2;
					$win = 1;
						echo "<center><font color='green'>Kazand?! :) </font>";
						
						$db->Query("UPDATE db_users_b SET money_b = money_b + '$sum' where id = '$usid'");
						$db->Query("INSERT INTO db_penny (user_id, login, date, summa, win) VALUES ('$usid', '$uname', '$time', '$sum', '$win')");
						
					} else {
						echo "<center><font color='red'>Kay?p! :(</font>";
						$win = 0;
						$db->Query("UPDATE db_users_b SET money_b = money_b - '$stavka' where id = '$usid'");
						$db->Query("INSERT INTO db_penny (user_id, login, date, summa, win) VALUES ('$usid', '$uname', '$time', '$stavka', '$win')");
					}
				}else echo "<center><font color='red'>para secin!</font>";
			}else echo "<center><font color='red'>10 gumus asgari oran!</font>";
		}else echo "<center><font color='red'>Yetersiz Fonlar!</font>";
}
?>


<BR />
<center>Oyunun mant?k cok basittir<BR /></center>
<center>Ucret Almak icin tahmin   etmek gereklidir!<BR /></center>
<center>Eger kazan?rsan senin bahis 1,2 kat artar ve sat?n almalar icin denge yans?t?l?r!</center>
<BR />
<center>

<form method="post" action="">

<input class="poilop" type="text" style="text-align:center" name="stavka" value="100"><br>
<center>
<table align="center">
<tr>
<td>
<?php
if ($win == 1 and $naper == 1) {
?>
<img src="/img/arel1.png">
<? } else { ?>
<img src="/img/arel.png">
<? } ?>
</td>
<td>
&nbsp;
</td>
<td>
<?php
if ($win == 1 and $naper == 2) {
?>
<img src="/img/reshka1.png">
<? } else { ?>
<img src="/img/reshka.png">
<? } ?>
</td>

<td>
<?php
if ($win == 1 and $naper == 3) {
?>

<? } else { ?>

<? } ?>
</td>

<tr>
<td>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input type="radio" name="naper" value="1">
</td>
<td>
&nbsp;
</td>
<td>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input type="radio" name="naper" value="2">
</td>



</tr>

</table>
</center>
<br>
<input style="height:25px;" class="btn_2d" type="submit" value="Èã?àòü">

</form>

<table cellpadding='3' cellspacing='0' border='0' bordercolor='#336633' align='center' width="99%">
  
  <td colspan="5" align="center"><h4>En son oyunlar</h4></td>
  
  
  <tr>
    <td align="center" class="m-tb">Toplam</td>
	<td align="center" class="m-tb">Tarih</td>
	<td align="center" class="m-tb">Durum</td>
	
  </tr>
  <?PHP
  
  $db->Query("SELECT * FROM db_penny WHERE user_id = '$usid' ORDER BY id DESC LIMIT 20");
  
	if($db->NumRows() > 0){
  
  		while($ref = $db->FetchArray()){
		if ($ref["win"] == 1) { 
		$winn = '<font color="green">Kazand?</font>'; 
		} else { 
		$winn = '<font color="red">Kay?p</font>'; 
		}
		$date = date('d-m-Y', $ref["date"]);
		?>
		<tr class="htt">
    		<td align="center"><?=$ref["summa"]; ?> </td>
			<td align="center"><?=$date; ?></td>
			<td align="center"><?=$winn; ?></td>
    		
  		</tr>
		<?PHP
		
		}
  
	}else echo '<tr><td align="center" colspan="5">Kay?t Yok</td></tr>'
  
  ?>

  
  
</table>

<div class="clr"></div>		
</div>

</div>