Jump to content
MakeWebGames

Mr-Scripts

Members
  • Posts

    60
  • Joined

  • Last visited

Everything posted by Mr-Scripts

  1. details of the probelm would help or what you are trying to do so one of the community members can lend you a hand or give you advice
  2. seems wired i cant find it any where
  3. Thank you Guest i have private messaged you a link and demo account to use   Plus here a link of in game features the hacker used my_account,profile [ATTACH=CONFIG]916[/ATTACH] No password [ATTACH=CONFIG]917[/ATTACH]
  4. its a base game but i dont know what it was orginally called ive just developed it from the source i was given i can provide demo if needed
  5. Well recently it was hacked things i cant get my head around. 1. the hacker could make a account without having a password ( even though on register you need to fill in all forms password username etc ) No one knows my cpanel or msql passwords and no one else has acess to my pc plus my passwords are 18 long with upper and lower case with symbols 2. he was randomly staff then after i banned him the person came back as a user and did the same even though he was`nt staff he could ban and kill people etc   3. [ATTACH=CONFIG]914[/ATTACH] Points 3 shows and example of what i have in place where every page players use/ and if that put anything after the .php the guy that hacked it when i clicked on what pages he used none of them where unnormal basically he clicked in game features he did not access staff panels as there protected by htaccess ive had to take my game down till i get a idea what the person did/ get more time to make sure its secure
  6. why like that site
  7. you on about the banner part got any screenshots
  8. what i need is a new layout/design made for my game simulair to the image above as my old one is a bit dated
  9. Uploaded with ImageShack.us Uploaded with ImageShack.us WORKING WITH THE FOLLOWING <frameset rows="30,*" cols="2" frameborder="NO" border="0" framespacing="0"> <frame src="banner.php" name="topFrame" scrolling="NO" marginwidth="0" marginheight="0"> <frameset rows="25,*" cols="" frameborder="NO" border="0" framespacing="0"> <frame src="mini2.php" name="topFrame" scrolling="NO" marginwidth="0" marginheight="0"> <frameset rows="*" cols="180,*" framespacing="0" frameborder="NO" border="0"> <frame src="mentest.php" name="leftFrame" noresize> <frame src="welcome.php" name="middleF"> <noframes> </noframes>
  10. Mr-Scripts

    help / info

    im looking to make a simple site for my girlfriends brother something like http://www.discountfootballkits.com/ http://www.clublinefootball.com/ http://www.newitts.com/ can these or something simulair be achived by prestashop or opencart ? whats the best one to use
  11. Mr-Scripts

    Buy Credits

    what do you suggest doing here
  12. Mr-Scripts

    Buy Credits

    Handling Variables Upon successful completion of a transaction, the Green Light Billing Server redirects your customer to a page of your choice (your "PassURL"). Whilst carrying out this redirect, we also post data a series of data to that page via HTTP Post. Some of this data is standard system information, whilst other data can be supplied by you. In other words, you can insert additional fileds into the web form we have provided you with (using the naming convention set out below) and we will return that data to your Pass URL following successful payment. The data included in this can be divided into two categories: 1. User Variables. Data sent by your website (via the "launch form") such as your unique reference, customer ID, postal address etc. 2. System Variables. Standard information about the transaction which you may find useful to know and use. VARIABLE NAMING AND EXPLANATIONS Name Type Description CovNum System The Receipt Code / Keycode generated by Green Light and issued to the customer. This is a unique reference so you may wish to make use of it. Password System This particularly useful for secure verification when receiving post data from us. You will receive your account password along with this data, and you can verify that it is correct in order to prevent misuse of the system. NB this is only passed to you via the HTTP post method i.e. it is not sent via email for security reasons. method System Payment method used by cuistomer - Telephone, SMS, Credit Card orDebit Card. payment System This is the value of "outpayment" due from Green Light to you for this specific transaction. price System The price of this product, as set by you. var1 User This is an open variable that can be used for any purpose you require. For example, if you have captured a customer telephone number and wish to receive that data back again at the end of the process along with the data above, simply name a form field "var1" and you will receive the data back with that same name following a successful transaction. var2 User as above var3 User as above var4 User as above var5 User as above var6 User as above var7 User as above var8 User as above var9 User as above var10 User as above Cust_Name User Whilst this is a user variable and can in theory be used for any data you wish, we have reserved it for the name of your customer. Cust_Email User as above Please ensure that you use the exact spelling and case stated above for all variables.
  13. Mr-Scripts

    Buy Credits

    Firstly thank you for taking the time to look or glance here i have a problem when gaining credits via glpayment i use the keycode i i get when texting it in i use it on this page and i do not gain the credits/points on the account i think its something to do with line 162where it asks for a password what do i put as the password ??   <? session_start(); include_once "includes/db_connect.php"; include_once"includes/functions.php"; logincheck(); $username=$_SESSION['username']; $query=mysql_query("SELECT * FROM users WHERE username='$username'"); $fetch=mysql_fetch_object($query); $query1=mysql_query("SELECT * FROM user_info WHERE username='$username'"); $user=mysql_fetch_object($query1); $creds=strip_tags($_GET['creds']); ?> <html> <head> <title>Blank</title> <script language=JavaScript> <!-- //Disable right click script III- By Renigade ([email protected]) //For full source code, visit http://www.dynamicdrive.com var message=''; /////////////////////////////////// function clickIE() {if (document.all) {(message);return false;}} function clickNS(e) {if (document.layers||(document.getElementById&&!document.all)) { if (e.which==2||e.which==3) {(message);return false;}}} if (document.layers) {document.captureEvents(Event.MOUSEDOWN);document.onmousedown=clickNS;} else{document.onmouseup=clickNS;document.oncontextmenu=clickIE;} document.oncontextmenu=new Function('return false') // --> </script> <link rel="shortcut icon" href="favicon.png"> <link href="style.css" rel="stylesheet" type="text/css"> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <table width="350" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="" class="table"> <tr><td align=center>Please note when you are <b>CLAIMING</b> credits that the URL <b>MUST</b> be <b>URL</b> thank you!<br><br><font color=red>You Buy Credits At Your Own Risk, We Stand On A Non Refundable Policy!</font> </td></tr></table><br> <table width="350" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="" class="table"> <tr><td class="header" colspan="5">Buying Credits - Mobile & Home Phone</td> </tr> <tr class="subhead"><td class="tableborder" align="center" ><u>Cost</u></td> <td class="tableborder" align="center" ><u>Amount</u></td> <td class="tableborder" align="center" ><u>Text</u></td> <td width="20%" align="center" class="tableborder" ><u>Claim</u></td> </tr> <tr><td width="14%" align="center" class="tableborder">£1.50</div></td> <td width="14%" align="center" class="tableborder">120</td> <td width="27%" align="center" class="tableborder">GL pay to 87070</td> <td width="20%" align="center" class="tableborder"><a href="?creds=120">Claim!</a></td> </tr> <tr><td width="14%" align="center" class="tableborder">£3.00</div></td> <td width="14%" align="center" class="tableborder">250</td> <td width="27%" align="center" class="tableborder">GL prem to 87070</td> <td width="20%" align="center" class="tableborder"><a href="?creds=250">Claim!</a></td> </tr> <tr><td width="14%" align="center" class="tableborder">£4.50</div></td> <td width="14%" align="center" class="tableborder">420</td> <td width="27%" align="center" class="tableborder">GL token to 87070</td> <td width="20%" align="center" class="tableborder"><a href="?creds=420">Claim!</a></td> </tr> <tr><td width="14%" align="center" class="tableborder">£6.00</div></td> <td width="14%" align="center" class="tableborder">670</td> <td width="27%" align="center" class="tableborder">GL bonus to 87070</td> <td width="20%" align="center" class="tableborder"><a href="?creds=670">Claim!</a></td> </tr> <tr><td width="14%" align="center" class="tableborder">£7.50</div></td> <td width="14%" align="center" class="tableborder">830</td> <td width="27%" align="center" class="tableborder">GL cool to 87070</td> <td width="20%" align="center" class="tableborder"><a href="?creds=830">Claim!</a></td> </tr> <tr><td width="14%" align="center" class="tableborder">£9.00</div></td> <td width="14%" align="center" class="tableborder">900</td> <td width="27%" align="center" class="tableborder">GL shot to 87070</td> <td width="20%" align="center" class="tableborder"><a href="?creds=900">Claim!</a></td> </tr> </table> <? if ($fetch->pban == "0"){ ?> <br> <br> <table width="25%" border="0" align="center" cellpadding="3" cellspacing="1" bordercolor="#000000" class="table"> <tr> <td colspan=2 class="header">Donate by Paypal </center></td> </tr> <tr> <td align="center" ><form action="https://www.paypal.com/cgi-bin/webscr" method="post" target=_blank> <center> <select name=amount class=textinput> <option value=5.00 >£5.00 - 480 Credits</option> <option value=10.00 >£10.00 - 1,200 Credits</option> <option value=15.00 >£15.00 - 1,920 Credits</option> <option value=20.00 >£20.00 - 2,520 Credits</option> <option value=25.00 >£25.50 - 3,300 Credits</option> <option value=30.00 >£30.00 - 4,200 Credits</option> <option value=100.00 >£100.00 - 16,800 Credits</option> </select> <input type="hidden" name="cmd" value="_xclick"> <input type="hidden" name="currency_code" value="GBP"> <input type="hidden" name="business" value="Hidden"> <input type="hidden" name="item_name" value="Hidden"> <input type="submit" class="button" border="0" value="Continue" onClick="confirmbuy()" name="submit" alt="Click To Redeem Your Points"> </center> </form></td> </tr> </table><? } ?><br> <?php if ($creds == "120"){ $id = "13040"; } if ($creds == "250"){ $id = "13553"; } if ($creds == "420"){ $id = "13222"; } if ($creds == "670"){ $id = "12643"; } if ($creds == "830"){ $id = "12644"; } if ($creds == "900"){ $id = "12645"; } if ($creds != ""){ ?> <form name="glform" method="post" action="http://www.glpayment.co.uk/glpay0205/Auth_Standard.php"> <table align="center" class="table" width="20%" cellpadding="3" cellspacing="1" border="0"> <tr><td class="header">Claim Credits - Keycodes</td></tr> <tr><td align="center" class="tableborder" > Keycode: <input type="text" class="textinput" name="number"><br><br> <input type="submit" class="button" value="Submit Keycode"> <input type="hidden" name="ddi_id" value="<? echo "$id"; ?>"> </td></tr> </table> </form> <br><br> <? } if ($_GET[payment] != ""){ if($_GET[payment] == "true" && $_POST[price] && $_POST[Password] == "" && $_POST[CovNum]) { $query = mysql_query("SELECT keycode FROM payments WHERE keycode='$_POST[CovNum]'"); $rows = mysql_num_rows($query); if($rows == 0) { if($_POST[price] == "1.50"){ $credgain = "120"; } elseif($_POST[price] == "3.00"){ $credgain = "250"; } elseif($_POST[price] == "4.50"){ $credgain = "420"; } elseif($_POST[price] == "6.00"){ $credgain = "670"; } elseif($_POST[price] == "7.50"){ $credgain = "830"; } elseif($_POST[price] == "9.00"){ $credgain = "900"; } mysql_query("UPDATE users SET points=points+$credgain WHERE username='$username'"); mysql_query("UPDATE users SET donate='Yes' WHERE username='$username'"); mysql_query("INSERT INTO payments SET username='$username', keycode='$_POST[CovNum]', date=NOW(''), creds='$credgain'"); echo "<div class=success>Thanks for donating $credgain credits have been added to your account $username<br><br>"; }else{ echo "<center><font color=red><b>The keycode entered has been used before.<br><br>"; } }else{ echo "<center><font color=red><b>This keycode has been used before or is invalid.<br><br>"; }} ?> <br>
  14. will do but its extremly bugged and not that well secured to be honest
  15. in your opinion whats the best to use for the above code ( plus how or where can i learn to secure it )
  16. Mr-Scripts

    BlackJack

    Thanks again for some valuable advice :) player have said if the max bet is set high and they log out and log back in sometimes it doubles there money i have notice alot of - profits on the phpmyadmin page too on the blackjack table
  17. Thank you kyle ill have a look like i said in a previous topic im still learning so any tips or way you can secure the sendmoney.php file or where i can read up about i use php.net already
  18. suggestion please
  19. * ill obviously change ereg to preg_match but i dont have anything in my functions
  20. if($_POST['Send_button']){ $send_amount=intval(strip_tags($_POST['send_amount'])); $to_person = strip_tags($_POST['to_person']); if (!$to_person){ echo "Please enter a username."; }elseif ($to_person){ $num_true=mysql_num_rows(mysql_query("SELECT * FROM users WHERE username='$to_person'")); if ($num_true == 0){ echo "No such user."; }elseif ($num_true != 0){ if ($send_amount > "0"){ if ($send_amount == 0 || !$send_amount || ereg('[^0-9]',$send_amount)){ print "You cant send that amount."; }elseif ($send_amount != 0 || $send_amount || !ereg('[^0-9]',$send_amount)){ { if ($send_amount > $fetch->bank){ echo "You do not have that much money in your bank."; }elseif ($send_amount <= $fetch->bank){ $newer = mysql_query("SELECT * FROM users WHERE username='$to_person'"); $abcdef=mysql_fetch_object($newer);
  21. Mr-Scripts

    Bug Fix Help

    can i duplicate the line and change alive to banner or can i have ALive or banned on the same line ( 11)
  22. Mr-Scripts

    Bug Fix Help

    thanks in advance
  23. are you refering to send money if so i dont think i do im new to this so what you see in the file is what i have
  24. Mr-Scripts

    Bug Fix Help

    A Player has pointed out that if you are banned on my game and start again and revive that account it becomes unbanned ( credit option ) bu what can i add to my exsiting code to prevent this   }} elseif($type==3){ $reviveuser = $_POST['reviveuser']; if($fetch->points < 1000){ echo " <table border=0 bordercolor=black align=center cellpadding=2 cellspacing=0><tr><td class=notice align=center><center><font color=red>You do not have enough credits to revive $reviveuser!</td></tr></table><br>"; } elseif($fetch->points >= 1000){ $query = mysql_query("SELECT * FROM users WHERE username='$reviveuser'"); $rows = mysql_num_rows($query); $userdata = mysql_fetch_object($query); if ($rows == "0"){ echo " <table border=0 bordercolor=black align=center cellpadding=2 cellspacing=0><tr><td class=notice align=center><center>The username entered to revive is invalid."; }else{ if ($userdata->status == "Alive"){ echo " <table border=0 bordercolor=black align=center cellpadding=2 cellspacing=0><tr><td class=notice align=center><center>That user is still alive!"; }else{ mysql_query("UPDATE users SET status='Alive',health='100' WHERE username='$reviveuser'"); mysql_query("UPDATE users SET points=points-1000 WHERE username='$username'"); mysql_query("INSERT INTO `spentcredits` (`id`, `username`, `product`, `cost`, `date`) VALUES ('', '$username', 'Revive - $reviveuser', '1000','$date')"); echo " <table border=0 bordercolor=black align=center cellpadding=2 cellspacing=0> <tr><td class=notice align=center><center><font color=green>You have revived $reviveuser they can now continue playing!</td> </tr> </table><br>"; }}}}
  25. Mr-Scripts

    BlackJack

    can some one help find the error i thibk its a math problem   <?php session_start(); include "includes/db_connect.php"; include "includes/functions.php"; if ($info->last_script_check < time()){ include_once "probe.php"; } logincheck(); $playersusername = $_SESSION['username']; $username = $_SESSION['username']; $fetch= mysql_fetch_object(mysql_query("SELECT * FROM users WHERE username='$username'")); $ding_dong1=mysql_fetch_object(mysql_query("SELECT * FROM bj WHERE location='$fetch->location'")); if($ding_dong1->bjowner == "0" || $ding_dong1->bjowner == ""){ ?></p> <link rel=stylesheet href=style.css type=text/css> <form name="form1" method="post" action=""> <table width="40%" border="0" align="center" cellpadding="0" cellspacing="0" class="table"> <tr><td height="30" align="center" class="header">BlackJack Unowned - <a href='?price' class="hover" title="<center>To Purchase This BlackJack It Will Cost You £5,000,000!">Price?</a></td></tr> <tr > <td align="center">The BlackJack Located In <b><?php echo "$fetch->location"; ?></b> Are Not Owned By Anyone!<br /> <br /> <input name="buyrps" id="buyrps" type="submit" class="button" value="Purchase" /> <br /> <br /> <br /> <?php if($_POST['buyrps']){ if($fetch->money < 5000000){ echo "You have not got £5,000,000 to pay for the BlackJack."; }elseif($fetch->money > 5000000 && $ding_dong1->bjowner == "0"){ $moneyless = $sitestats->factoryprice; mysql_query("UPDATE users SET money=money-5000000 WHERE username='$username'"); mysql_query("UPDATE bj SET bjowner='$username' WHERE location='$fetch->location'"); echo "You now own the BlackJack located in $fetch->location."; }} ?> </td> </tr> </table> </form> <?php }else{ ?> <?php $time = time(); echo "$style"; ?> <? if($info->bettingban=='1'){ die("<center><h3><font colour='FFFFFF'>You Have Been Banned From This Page</h3></center>"); } $fetch=mysql_fetch_object(mysql_query("SELECT username,location FROM users WHERE username='$username'")); echo " <link href=style.css rel=stylesheet type=text/css> "; $username = $_SESSION['username']; $self = "blackjack.php"; //***get info $result = mysql_query("SELECT money, location FROM users WHERE username='$username'"); while ($info = mysql_fetch_row($result)) { $pmoney = $info[0]; $currentmoney = $info[0]; $state = $info[1]; $location= $info[1]; $bj = $info[2]; } ///// $ding_dong=mysql_fetch_object(mysql_query("SELECT bjowner FROM bj WHERE location ='$fetch->location'")); $ding_dong1=mysql_fetch_object(mysql_query("SELECT * FROM bj WHERE location ='$fetch->location'")); $fat_****=mysql_fetch_object(mysql_query("SELECT username,status FROM users WHERE username='$ding_dong->bjowner'")); ///// if($fat_****->status == 'Dead' || $fat_****->status == 'Banned'){ mysql_query("UPDATE bj SET bjowner='0' WHERE location='$location'"); print "<font color=white>This table has no owner!"; exit(); } if(!$_SESSION['con']){ $_SESSION['con']=$state; }elseif($_SESSION['con']!=$state){ echo "<center><font color=red><b>You flew and lost your cards!<BR>"; unset($_SESSION['deck'],$_SESSION['card1'],$_SESSION['color1'],$_SESSION['card2'],$_SESSION['card3'],$_SESSION['color3'],$_SESSION['card4'],$_SESSION['color4'],$_SESSION['card5'],$_SESSION['color5'],$_SESSION['card6'],$_SESSION['color6'],$_SESSION['dcard1'],$_SESSION['dcard2'],$_SESSION['dcard3'],$_SESSION['dcard4'],$_SESSION['con']); } $result = mysql_query("SELECT bjmaxbet, bjminbet, bjowner , bjearnings FROM bj WHERE location='$fetch->location'"); while ($info = mysql_fetch_row($result)) { $bjowner = $info[2]; $max = $info[0]; $earn = $info[3]; $bjmaxbet = $info[0]; $bjminbid = $info[1]; $totalearnings = $info[3]; $bjowner = $info[2]; } $result = mysql_query("SELECT id, money FROM users WHERE username='$bjowner'"); while ($info = mysql_fetch_row($result)) { $oid = $info[0]; $omoney = $info[1]; $otmoney = $info[1]; } if($bjowner == "None"){ echo "<font color=white>No owner"; exit(); } $offer = $_POST['offer']; $ownerstuff = mysql_query("SELECT money, id, status FROM users WHERE username='$bjowner'"); while($ownerstats = mysql_fetch_row($ownerstuff)){ $ownerscurrentmoney = $ownerstats[0]; $otmoney = $ownerstats[0]; $ownerid = $ownerstats[1]; $abd = $ownerstats[2]; } if($offer != ""){ if($offer < 0){ echo "<font color=white>You can't go below 0!"; } elseif($offer > 2147483647){ echo "<font color=white>Your offer is to high!"; } elseif(ereg("[^[:digit:]]", $offer)) { echo "<font color=white>Bad amount!"; } elseif($username == $bjowner){ echo "<font color=white>You can't make an offer to yourself!"; } elseif($offer > $currentmoney){ echo "<font color=white>You dont have that much money!"; } else { echo "You have made an offer to take over that blackjack!"; mysql_query("INSERT INTO `offers` ( `id` , `username` , `owner` , `offer` , `casino`, `location` ) VALUES ('', '$username', '$bjowner', '$offer', 'Blackjack', '$location');"); } } if($_POST['adeal']){ $yid = $_POST['yes']; $nid = $_POST['no']; if($yid != ""){ $ow = mysql_query("SELECT * FROM offers WHERE id='$yid'"); while($o = mysql_fetch_row($ow)){ $offerer = $o[1]; $bjowner = $o[2]; $moffer = $o[3]; $location = $o[5]; $casino = $o[4]; } $cost = mysql_query("SELECT money FROM users WHERE username='$offerer'"); while($money = mysql_fetch_row($cost)){ $oumoney = $money[0]; } if($oumoney < $moffer){ echo "<font color=white>That user no longer has enough money!"; } elseif($offerer == $username){ echo "<font color=white>You cant accept your own offer!"; } elseif($bjowner != $username){ echo "<font color=white>Thats not your blackjack!"; } else { mysql_query("UPDATE bj SET bjowner='$offerer' WHERE location='$location'"); $newownmoney = $currentmoney + $moffer; $newusemoney = $oumoney - $moffer; $message = "<font color=white>Your offer was <b>accepted</b> by <b>$bjowner</b> for the $location $casino for the price of $$moffer"; mysql_query("INSERT INTO `inbox` (`id`, `to`, `from`, `date`, `text`) VALUES ('', '$offerer', 'BlackJack Ownership', NOW(), '$message');"); mysql_query("UPDATE users SET money='$newownmoney' WHERE username='$username'"); mysql_query("UPDATE users SET money='$newusemoney' WHERE username='$offerer'"); mysql_query("DELETE FROM offers WHERE location='$location', bjmaxbet='100' AND casino='$casino'"); echo "<font color=white>You have accepted that offer!"; exit(); } } else { $ow = mysql_query("SELECT * FROM offers WHERE id='$nid'"); while($o = mysql_fetch_row($ow)){ $offerer = $o[1]; $bjowner = $o[2]; $moffer = $o[3]; $location = $o[5]; $casino = $o[4]; } $message = "Your offer was <b>declined</b> by <b>$bjowner</b> for $location $casino for the price of $$moffer"; mysql_query("INSERT INTO `inbox` (`id`, `to`, `from`, `date`, `text`) VALUES ('', '$offerer', 'Location Ownership', NOW(), '$message');"); mysql_query("DELETE FROM offers WHERE id='$nid'"); echo "<font color=white>You declined that offer!"; } } //see if person owns table if ($bjowner == $playersusername){ if ($_POST['newmaxbet']){ $newmaxbet = $_POST['newmaxbet']; if ($newmaxbet < 5000000){ echo "<center><font color=red><b>Max must be atleast £5,000,000 or above!"; //in exit(); }elseif ($newmaxbet > 10000000000){ echo "<center><font color=red><b>Max must be less then £10,000,000,000!"; //in exit(); }elseif(ereg("[^[:digit:]]", $newmaxbet)){ echo "<center><font color=white><b>Max bet must only contain numbers!"; //in exit(); }else{ mysql_query("UPDATE bj SET bjmaxbet='$newmaxbet' WHERE bjowner='$username' AND location='$location'"); echo "<center><font color=green><b>Your maxbet has been updated to £$newmaxbet"; } } if ($_POST['newminbid']){ $newminbid = $_POST['newminbid']; if ($newminbid < 100){ echo "<center><font color=red><b>Minimum bet must be atleast £100 or above!"; //in exit(); } if(ereg("[^[:digit:]]", $newminbid)){ echo "<font color=white>Minimum bet must only contain numbers!"; //in exit(); }elseif(!ereg("[^[:digit:]]", $newminbid)){ mysql_query("UPDATE bj SET bjminbet='$newminbid' WHERE bjowner='$username' AND location='$location'"); } echo "<center><font color=green><b>Minimum bet has been updated to £$newminbid!"; } if ($_POST['givetouser']){ $givetouser = $_POST['givetouser']; $checkgiveto = mysql_query("SELECT username FROM users WHERE username='$givetouser'"); $checkifexist = mysql_num_rows($checkgiveto); if($checkifexist <= 0){ echo "<center><font color=white><b>That user does not exist!"; //in exit(); }else{ while($giver = mysql_fetch_row($checkgiveto)){ $givetouser = $giver[0]; } $date = gmdate('Y-m-d h:i:s'); mysql_query("INSERT INTO `propsend` ( `id` , `type` , `location` , `usernamefrom` , `usernameto` , `date` ) VALUES ('', 'Blackjack', '$location', '$username', '$givetouser', '$date')"); mysql_query("UPDATE bj SET bjmaxbet='2500' WHERE bjowner='$username' AND location='$location'"); mysql_query("UPDATE bj SET bjowner='$givetouser' WHERE bjowner='$username' AND location='$location'"); echo "<center><font color=white><b>You gave $givetouser the Blackjack!"; } } if (strip_tags($_POST['drop']) == "Yes"){ mysql_query("UPDATE bj SET bjmaxbet='2500' WHERE bjowner='$username' AND location='$location'"); mysql_query("UPDATE bj SET bjowner='0', bjearnings='0' WHERE bjowner='$username' AND location='$location'"); echo"Dropped!"; exit(); } echo "<form method=post action=$self> <table width=300 align=center border=0 cellpadding=0 cellspacing=0 class=table> <tr class=header> <td colspan=4> Blackjack CP</td> </tr> <tr> <td width=130>Total Earnings: </td> <td width=148 colspan=3>£"; echo number_format($totalearnings); echo "</td> </tr> <tr> <td>Max Bet: </td> <td width=148 colspan=3><input name=newmaxbet type=text id=maxbet class=textbox1></td> </tr> <tr> <td>Current Max: </td> <td colspan=3>£"; echo number_format($bjmaxbet); echo "</td> </tr> <tr> <td>Drop:</td> <td><select name=drop id=drop class=\"textbox1\" style=\"width: 60px;\"> <option value=\"No\">No</option> <option value=\"Yes\">Yes</option> </select></td> </tr> <tr> <td>Give to: </td> <td colspan=3><input name=givetouser type=text id=giveto class=textbox1></td> </tr> <tr> <td> </td> <td colspan=4 align=center><input type=submit name=Submit value=Update class=button></td> </tr> </table><br> </form> "; //in exit(); } $suc = 1; if (isset($_POST['bett'])){ $bettt = strip_tags($_POST['bett']); $now = $bj + 60; if(time() < $now){ echo "<font color=white>You started a blackjack game and never finished you must wait a minuite to start another!"; exit(); }elseif(ereg("[^[:digit:]]", $bettt)) { echo "<font color=white>Bet amount can only contain numbers!"; $suc = 2; unset($_SESSION['bet']); }elseif($bettt > $pmoney){ echo "<font color=white>You dont have enough money!"; $suc = 2; unset($_SESSION['bet']); }elseif($bettt > 1000000000){ echo "<font color=white>Maximum is 1 billion!"; exit(); }elseif($bettt > $max) { echo "<font color=white>The current max is £$max!"; $suc = 2; unset($_SESSION['bet']); }else{ $_SESSION['bet'] = $bettt; $money = $pmoney - $bettt; mysql_query("UPDATE users SET money='$money', bj='$time' WHERE username='$username'"); $_SESSION['show'] = "show me"; unset($_SESSION['deck'],$_SESSION['card1'],$_SESSION['color1'],$_SESSION['card2'],$_SESSION['card3'],$_SESSION['color3'],$_SESSION['card4'],$_SESSION['color4'],$_SESSION['card5'],$_SESSION['color5'],$_SESSION['card6'],$_SESSION['color6'],$_SESSION['dcard1'],$_SESSION['dcard2'],$_SESSION['dcard3'],$_SESSION['dcard4']); } } $bet = $_SESSION['bet']; //****check if they want to hit if ((isset($_POST['hit'])) && (!isset($_POST['stand'])) && (isset($_SESSION['bet']))){ $deckk = $_SESSION['deck']; if (isset($_SESSION['card6'])){ }else{ $ex = "6"; } if (isset($_SESSION['card5'])){ }else{ $ex = "5"; } if (isset($_SESSION['card4'])){ }else{ $ex = "4"; } if (isset($_SESSION['card3'])){ }else{ $ex = "3"; } if ($ex == 3){ $card3 = explode("-", $deckk[2]); $color3 = $card3[1]; $card3 = $card3[0]; if ($color3 == "h"){$color3 = 'heart';} if ($color3 == "d"){$color3 = 'diamond';} if ($color3 == "s"){$color3 = 'spade';} if ($color3 == "c"){$color3 = 'club';} $_SESSION['card3'] = $card3; $_SESSION['color3'] = $color3; } if ($ex == 4){ $card4 = explode("-", $deckk[3]); $color4 = $card4[1]; $card4 = $card4[0]; if ($color4 == "h"){$color4 = 'heart';} if ($color4 == "d"){$color4 = 'diamond';} if ($color4 == "c"){$color4 = 'club';} if ($color4 == "s"){$color4 = 'spade';} $_SESSION['card4'] = $card4; $_SESSION['color4'] = $color4; } if ($ex == 5){ $card5 = explode("-", $deckk[4]); $color5 = $card5[1]; $card5 = $card5[0]; if ($color5 == "h"){$color5 = 'heart';} if ($color5 == "d"){$color5 = 'diamond';} if ($color5 == "c"){$color5 = 'club';} if ($color5 == "s"){$color5 = 'spade';} $_SESSION['card5'] = $card5; $_SESSION['color5'] = $color5; } if ($ex == 6){ $card6 = explode("-", $deckk[5]); $color6 = $card6[1]; $card6 = $card6[0]; if ($color6 == "h"){$color6 = 'heart';} if ($color6 == "d"){$color6 = 'diamond';} if ($color6 == "c"){$color6 = 'club';} if ($color6 == "s"){$color6 = 'spade';} $_SESSION['card6'] = $card6; $_SESSION['color6'] = $color6; } } //*****see if they stand if ((isset($_POST['stand'])) && (!isset($_POST['hit'])) && (isset($_SESSION['bet']))){ $bet = $_SESSION['bet']; $dcardd1 = $_SESSION['dcard1']; $dcardd2 = $_SESSION['dcard2']; if (($dcardd1 == 13) || ($dcardd1 == 12) || ($dcardd1 == 11)){ $dcardd1 = 10; } if ($dcardd1 == 14){ $dcardd1 = 11; } if (($dcardd2 == 13) || ($dcardd2 == 12) || ($dcardd2 == 11)){ $dcardd2 = 10; } if ($dcardd2 == 14){ $dcardd2 = 11; } $dtotal = $dcardd1 + $dcardd2; if (($dtotal > 21) && ($dcardd1 == 11)){ $dcardd1 = 1; $dtotal = $dtotal - 11; $dtotal = $dtotal + $dcardd1; } if (($dtotal > 21) && ($dcardd2 == 11)){ $dcardd2 = 1; $dtotal = $dtotal - 11; $dtotal = $dtotal + $dcardd2; } $dtotal = $dcardd1 + $dcardd2; if ($dtotal <= 16){ $deckk = $_SESSION['deck']; $dcard3 = explode("-", $deckk[49]); $dcolor3 = $dcard3[1]; $dcard3 = $dcard3[0]; if ($dcolor3 == "h"){$dcolor3 = 'heart';} if ($dcolor3 == "d"){$dcolor3 = 'diamond';} if ($dcolor3 == "c"){$dcolor3 = 'club';} if ($dcolor3 == "s"){$dcolor3 = 'spade';} $_SESSION['dcard3'] = $dcard3; $_SESSION['dcolor3'] = $dcolor3; $dcardd3 = $dcard3; if (($dcardd3 == 13) OR ($dcardd3 == 12) OR ($dcardd3 == 11)){ $dcardd3 = 10; } if ($dcardd3 == 14){ $dcardd3 = 11; } $dtotal = $dtotal + $dcardd3; if (($dtotal > 21) && ($dcardd3 == 11)){ $dcardd3 = 1; $dtotal = $dtotal - 11; $dtotal = $dtotal + $dcardd3; } } if (($dtotal <= 16) && (isset($_SESSION['dcard3']))){ $deckk = $_SESSION['deck']; $dcard4 = explode("-", $deckk[48]); $dcolor4 = $dcard4[1]; $dcard4 = $dcard4[0]; if ($dcolor4 == "h"){$dcolor4 = 'heart';} if ($dcolor4 == "d"){$dcolor4 = 'diamond';} if ($dcolor4 == "c"){$dcolor4 = 'club';} if ($dcolor4 == "s"){$dcolor4 = 'spade';} $_SESSION['dcard4'] = $dcard4; $_SESSION['dcolor4'] = $dcolor4; $dcardd4 = $dcard4; if (($dcardd4 == 13) OR ($dcardd4 == 12) OR ($dcardd4 == 11)){ $dcardd4 = 10; } if ($dcardd4 == 14){ $dcardd4 = 11; } $dtotal = $dtotal + $dcardd4; if (($dtotal > 21) && ($cardd4 == 11)){ $dcardd4 = 1; $dtotal = $dtotal - 11; $dtotal = $dtotal + $dcardd4; } } $cardd1 = $_SESSION['card1']; $cardd2 = $_SESSION['card2']; $cardd3 = $_SESSION['card3']; $cardd4 = $_SESSION['card4']; $cardd5 = $_SESSION['card5']; $cardd6 = $_SESSION['card6']; if (($cardd1 == 13) || ($cardd1 == 12) || ($cardd1 == 11)){ $cardd1 = 10; } if ($cardd1 == 14){ $cardd1 = 11; } if (($cardd2 == 13) || ($cardd2 == 12) || ($cardd2 == 11)){ $cardd2 = 10; } if ($cardd2 == 14){ $cardd2 = 11; } if (isset($_SESSION['card3'])){ if (($cardd3 == 13) || ($cardd3 == 12) || ($cardd3 == 11)){ $cardd3 = 10; } if ($cardd3 == 14){ $cardd3 = 11; } } if (isset($_SESSION['card4'])){ if (($cardd4 == 13) || ($cardd4 == 12) || ($cardd4 == 11)){ $cardd4 = 10; } if ($cardd4 == 14){ $cardd4 = 11; } } if (isset($_SESSION['card5'])){ if (($cardd5 == 13) || ($cardd5 == 12) || ($cardd5 == 11)){ $cardd5 = 10; } if ($cardd5 == 14){ $cardd5 = 11; } } if (isset($_SESSION['card6'])){ if (($cardd6 == 13) || ($cardd6 == 12) || ($cardd6 == 11)){ $cardd6 = 10; } if ($cardd6 == 14){ $cardd6 = 11; } } $total = $cardd1 + $cardd2; if (isset($_SESSION['card3'])){ $total = $total + $cardd3; } if (isset($_SESSION['card4'])){ $total = $total + $cardd4; } if (isset($_SESSION['card5'])){ $total = $total + $cardd5; } if (isset($_SESSION['card6'])){ $total = $total + $cardd6; } if (($total > 21) && ($cardd1 == 11)){ $cardd1 = 1; $total = $total - 11; $total = $total + $cardd1; } if (($total > 21) && ($cardd2 == 11)){ $cardd2 = 1; $total = $total - 11; $total = $total + $cardd2; } if (($total > 21) && ($cardd3 == 11)){ $cardd3 = 1; $total = $total - 11; $total = $total + $cardd3; } if (($total > 21) && ($cardd4 == 11)){ $cardd4 = 1; $total = $total - 11; $total = $total + $cardd4; } if (($total > 21) && ($cardd5 == 11)){ $cardd5 = 1; $total = $total - 11; $total = $total + $cardd5; } if (($total > 21) && ($cardd6 == 11)){ $cardd6 = 1; $total = $total - 11; $total = $total + $cardd6; } if (($dtotal > 21) && (isset($_SESSION['bet']))){ $hahahaha1=$bet; echo "<center><font color=green><b>The dealer has bust. You won £$hahahaha1."; $won = $bet; $newmoney = $omoney - $won; $ws = "win"; if($newmoney <= 0){ $bet = $bet; mysql_query("UPDATE bj SET bjowner='$username', bjearnings='0', bjmaxbet='2000' WHERE bjowner='$bjowner' AND location='$location'"); mysql_query("UPDATE users SET money='$otmoney' WHERE username='$bjowner'"); mysql_query("UPDATE bj SET bjowner='$username', bjearnings='0', bjmaxbet='2000' WHERE bjowner='$bjowner' AND location='$location'"); echo "<font color=white>You tookover the table"; die(); }else{ $money = $won + $pmoney; mysql_query("UPDATE users SET money='$money' WHERE username='$username'"); mysql_query("UPDATE users SET bjwins=bjwins+1 WHERE username='$username'"); $total = $earn - $won; mysql_query("INSERT INTO `betlogs` (`id`, `username`, `money`, `end`, `owner`, `type`, `moneyuse`) VALUES ('', '$username', '$currentmoney', '$end', '$bjowner', 'bj', '$bettt');"); mysql_query("UPDATE bj SET bjearnings='$total' WHERE bjowner='$bjowner'"); $newmoney = $omoney - $won; mysql_query("UPDATE users SET money='$newmoney' WHERE username='$bjowner'"); mysql_query("UPDATE users SET bj='0' WHERE username='$username'"); unset($_SESSION['deck'],$_SESSION['bet']); } $_SESSION['show'] = "show them"; } $phow = 21 - $total; $dhow = 21 - $dtotal; if (($phow > $dhow) && (isset($_SESSION['bet']))){ echo "<center><font color=red><b>You had $total and the dealer had $dtotal you lost £$bet!"; $total = $earn + $bet; $ws = "lost"; mysql_query("UPDATE bj SET bjearnings='$total' WHERE bjowner='$bjowner'"); $newmoney = $omoney + $bet; mysql_query("UPDATE users SET money='$newmoney' WHERE username='$bjowner'"); $start = $pmoney; $end = $pmoney-$bet; mysql_query("UPDATE users SET money='$end' WHERE username='$username'"); unset($_SESSION['deck'],$_SESSION['bet']); $_SESSION['show'] = "show them"; } if (($phow < $dhow) && (isset($_SESSION['bet']))){ $eat****=$bet; echo "<center><font color=green><b>You had $total and the dealer had $dtotal you won £$eat****!"; $won = $bet; $newmoney = $omoney - $won; $ws = "win"; if($newmoney <= 0){ $bet = $bet; mysql_query("UPDATE bj SET bjowner='$username',bjearnings='0',bjmaxbet='2000' WHERE bjowner='$bjowner' AND location='$location'"); mysql_query("UPDATE users SET money='$otmoney' WHERE username='$bjowner'"); mysql_query("UPDATE users SET money=money+bet WHERE username='$username'"); echo "<center><font color=green><b>The owner has no money left so you tookover the table!"; }else{ $money = ($won) + $pmoney; mysql_query("UPDATE users SET money='$money' WHERE username='$username'"); mysql_query("UPDATE users SET bjwins=bjwins+1 WHERE username='$username'"); $total = $earn - $won; mysql_query("UPDATE bj SET bjearnings='$total' WHERE bjowner='$bjowner'"); $newmoney = $omoney - $won; mysql_query("UPDATE users SET money='$newmoney' WHERE username='$bjowner'"); mysql_query("UPDATE users SET bj='0' WHERE username='$username'"); unset($_SESSION['deck'],$_SESSION['bet']); } $_SESSION['show'] = "show them"; } if (($phow == $dhow) && ($bet)){ $bet = $bet; echo "<center><font color=white><b>It was a push both you and dealer had same amount!"; mysql_query("UPDATE users SET money=money+$bet, bj='0' WHERE username='$username'"); unset($_SESSION['deck'],$_SESSION['bet']); $_SESSION['show'] = "show them"; } } if ((!isset($_SESSION['card1'])) && (isset($_SESSION['bet']))){ $bet = $_SESSION['bet']; //*********get cards //make a deck $cards = array("14-h", "14-c", "14-d", "14-s", "2-h", "2-c", "2-d", "2-s", "3-h", "3-c", "3-d", "3-s", "4-h", "4-c", "4-d", "4-s", "5-h", "5-c", "5-d", "5-s", "6-h", "6-c", "6-d", "6-s", "7-h", "7-c", "7-d", "7-s", "8-h", "8-c", "8-d", "8-s", "9-h", "9-c", "9-d", "9-s", "10-h", "10-c", "10-d", "10-s", "11-h", "11-c", "11-d", "11-s", "12-h", "12-c", "12-d", "12-s", "13-h", "13-c", "13-d", "13-s"); //shuffle for($i = 0; $i < 52; $i++){ $count = count($cards); $random = (rand()%$count); if($cards[$random] == "") { $i--; } else{ $deck[] = $cards[$random]; $cards[$random] = ""; } } $_SESSION['deck'] = $deck; $carrd1 = explode("-", $deck[0]); $card1 = $carrd1[0]; $color1 = $carrd1[1]; $carrd2 = explode("-", $deck[1]); $card2 = $carrd2[0]; $color2 = $carrd2[1]; if ($color1 == "h"){$color1 = 'heart';} if ($color1 == "d"){$color1 = 'diamond';} if ($color1 == "c"){$color1 = 'club';} if ($color1 == "s"){$color1 = 'spade';} $_SESSION['card1'] = $card1; $_SESSION['color1'] = $color1; //second card if ($color2 == "h"){$color2 = 'heart';} if ($color2 == "d"){$color2 = 'diamond';} if ($color2 == "c"){$color2 = 'club';} if ($color2 == "s"){$color2 = 'spade';} $_SESSION['card2'] = $card2; $_SESSION['color2'] = $color2; //get dealer cards $dcarrd1 = explode("-", $deck[50]); $dcard1 = $dcarrd1[0]; $dcolor1 = $dcarrd1[1]; $dcarrd2 = explode("-", $deck[51]); $dcard2 = $dcarrd2[0]; $dcolor2 = $dcarrd2[1]; if ($dcolor1 == "h"){$dcolor1 = 'heart';} if ($dcolor1 == "d"){$dcolor1 = 'diamond';} if ($dcolor1 == "c"){$dcolor1 = 'club';} if ($dcolor1 == "s"){$dcolor1 = 'spade';} $_SESSION['dcard1'] = $dcard1; $_SESSION['dcolor1'] = $dcolor1; //second card if ($dcolor2 == "h"){$dcolor2 = 'heart';} if ($dcolor2 == "d"){$dcolor2 = 'diamond';} if ($dcolor2 == "c"){$dcolor2 = 'club';} if ($dcolor2 == "s"){$dcolor2 = 'spade';} $_SESSION['dcard2'] = $dcard2; $_SESSION['dcolor2'] = $dcolor2; } //calcualte cards total to see if they have Blackjack or have bust if (isset($_SESSION['card1'])){ $cardd1 = $_SESSION['card1']; $cardd2 = $_SESSION['card2']; $cardd3 = $_SESSION['card3']; $cardd4 = $_SESSION['card4']; $cardd5 = $_SESSION['card5']; $cardd6 = $_SESSION['card6']; if (($cardd1 == 13) || ($cardd1 == 12) || ($cardd1 == 11)){ $cardd1 = 10; } if ($cardd1 == 14){ $cardd1 = 11; } if (($cardd2 == 13) OR ($cardd2 == 12) OR ($cardd2 == 11)){ $cardd2 = 10; } if ($cardd2 == 14){ $cardd2 = 11; } if (isset($_SESSION['card3'])){ if (($cardd3 == 13) OR ($cardd3 == 12) OR ($cardd3 == 11)){ $cardd3 = 10; } if ($cardd3 == 14){ $cardd3 = 11; } } if (isset($_SESSION['card4'])){ if (($cardd4 == 13) OR ($cardd4 == 12) OR ($cardd4 == 11)){ $cardd4 = 10; } if ($cardd4 == 14){ $cardd4 = 11; } } if (isset($_SESSION['card5'])){ if (($cardd5 == 13) OR ($cardd5 == 12) OR ($cardd5 == 11)){ $cardd5 = 10; } if ($cardd5 == 14){ $cardd5 = 11; } } if (isset($_SESSION['card6'])){ if (($cardd6 == 13) OR ($cardd6 == 12) OR ($cardd6 == 11)){ $cardd6 = 10; } if ($cardd6 == 14){ $cardd6 = 11; } } $total = $cardd1 + $cardd2; if (isset($_SESSION['card3'])){ $total = $total + $cardd3; } if (isset($_SESSION['card4'])){ $total = $total + $cardd4; } if (isset($_SESSION['card5'])){ $total = $total + $cardd5; } if (isset($_SESSION['card6'])){ $total = $total + $cardd6; } if (($total > 21) && ($cardd1 == 11)){ $cardd1 = 1; $total = $total - 11; $total = $total + $cardd1; } if (($total > 21) && ($cardd2 == 11)){ $cardd2 = 1; $total = $total - 11; $total = $total + $cardd2; } if (($total > 21) && ($cardd3 == 11)){ $cardd3 = 1; $total = $total - 11; $total = $total + $cardd3; } if (($total > 21) && ($cardd4 == 11)){ $cardd4 = 1; $total = $total - 11; $total = $total + $cardd4; } if (($total > 21) && ($cardd5 == 11)){ $cardd5 = 1; $total = $total - 11; $total = $total + $cardd5; } if (($total > 21) && ($cardd6 == 11)){ $cardd6 = 1; $total = $total - 11; $total = $total + $cardd6; } if (($total == "21") && (!isset($_SESSION['card3'])) && (isset($_SESSION['bet']))){ $bj = ($bet)/2; $won=$bet+$bj; $newmoney = $omoney - $won; $ws = "bj"; if($newmoney <= 0){ $bet = $bet; mysql_query("UPDATE bj SET bjowner='$username',bjearnings='0',bjmaxbet='2000' WHERE bjowner='$bjowner' AND location='$location'"); mysql_query("UPDATE users SET money='$otmoney' WHERE username='$bjowner'"); mysql_query("UPDATE users SET money=money+$bet WHERE username='$username'"); echo "<font color=white>You tookover the table"; }else{ echo "<center><font color=green><b>You got 21 and won £$won "; $money = ($won) + $pmoney; mysql_query("UPDATE users SET money='$money' WHERE username='$username'"); mysql_query("UPDATE users SET bjwins=bjwins+1 WHERE username='$username'"); $total = $earn - $won; mysql_query("UPDATE bj SET bjearnings='$total' WHERE bjowner='$bjowner'"); $newmoney = $omoney - $won; mysql_query("UPDATE users SET money='$newmoney' WHERE username='$bjowner'"); mysql_query("UPDATE users SET bj='0' WHERE username='$username'"); $_SESSION['show'] = "show them"; unset($_SESSION['deck'],$_SESSION['bet']); } $_SESSION['show'] = "show them"; } if (($total > "21" ) && (isset($_SESSION['bet']))){ $lost = $bet; $ws = "lost"; echo "<center><font color=red><b>You had $total. You bust and lost £$lost. "; $total = $earn + $lost; mysql_query("UPDATE bj SET bjearnings='$total' WHERE bjowner='$bjowner'"); $newmoney = $omoney + $lost; mysql_query("UPDATE users SET money='$newmoney' WHERE username='$bjowner'"); $start = $pmoney; $end = $pmoney-$bet; mysql_query("UPDATE users SET money='$end' WHERE username='$username'"); $_SESSION['show'] = "show them"; unset($_SESSION['deck'],$_SESSION['bet']); $_SESSION['show'] = "show them"; } } if($ws == "lost"){ $start = $pmoney; $end = $pmoney-$bet; mysql_query("INSERT INTO `betlogs` (`id`, `username`, `money`, `end`, `owner`, `type`) VALUES ('', '$username', '$start', '$end', '$bjowner', 'bj');"); }elseif($ws == "win"){ $start = $pmoney; $end = $pmoney+($bet); mysql_query("INSERT INTO `betlogs` (`id`, `username`, `money`, `end`, `owner`, `type`) VALUES ('', '$username', '$start', '$end', '$bjowner', 'bj');"); }elseif($ws == "bj"){ $start = $pmoney; $end = $pmoney+($bet)+($bet/2); mysql_query("INSERT INTO `betlogs` (`id`, `username`, `money`, `end`, `owner`, `type`) VALUES ('', '$username', '$start', '$end', '$bjowner', 'bj');"); } if (!isset($_SESSION['bet'])){ echo " <center> <form name=form3 method=post action=$self> <br> <table width=270 align=center cellspacing=0 cellpadding=0 class=table> <tr><td class=header colspan=4>Blackjack</td></tr> <tr> <td colspan=3 align=center>Place Your Bet:</td> <td><input type=text name=bett class=textbox1></td> </tr> <tr> <td colspan=3 align=left> </td> <td align=left><input type=submit class=button name=Submit value=Bet></td> </tr> </table></form><br> <table width=25% align=center border=0 cellspacing=0 cellpadding=0 class=table> <tr> <td align=center class='header' colspan=4>Blackjack Stats</td></tr> <tr><td align=center>"; if ($bjowner == "0"){ echo "This Blackjack table is not owned by anyone<br>The max bet is set at £".makecomma($bjmaxbet).""; }else{ echo "This Blackjack table is owned by <a href='profile.php?viewuser=$bjowner'><b>$bjowner</b></a><br>The max bet is set at £".makecomma($bjmaxbet).""; } echo"</td></tr></table>"; include_once"footer_bottom.php"; die(); } else { echo " "; } if ((isset($_SESSION['dcard1'])) && (isset($_SESSION['show']))){ ?> <br> <table width=600 align=center cellspacing=0 cellpadding=0 class=table> <tr><td class=header colspan=11>Blackjack</td></tr> <tr width=600> <td width="50%" valign=top> <center> <b>Dealers Cards</b><br><br> <img src="images/cards/<?php if ((isset($_SESSION['dcard1'])) && (isset($_SESSION['show']))){ echo $_SESSION['dcolor1']; }else{ echo "cardback";} echo "/"; if ((isset($_SESSION['dcard1'])) && (isset($_SESSION['show']))) { echo $_SESSION['dcard1']; }else{ echo "cardback";}?>.gif" width="93" height="120"> <img src=images/cards/<?php if ((isset($_SESSION['dcard2'])) && (isset($_POST['stand'])) && (isset($_SESSION['show']))) { echo $_SESSION['dcolor2']; }else{ echo "cardback"; } echo "/"; if ((isset($_SESSION['dcard2'])) && (isset($_POST['stand'])) && (isset($_SESSION['show']))) { echo $_SESSION['dcard2']; }else{ echo "cardback";} ?>.gif width="93" height="120"> <?php if ((isset($_SESSION['dcard3'])) && (isset($_POST['stand'])) && (isset($_SESSION['show']))) { echo "<img src=images/cards/"; echo $_SESSION['dcolor3']; echo "/"; echo $_SESSION['dcard3']; echo ".gif width=71 height=96>"; echo " "; } if ((isset($_SESSION['dcard4'])) && (isset($_POST['stand'])) && (isset($_SESSION['show']))) { echo "<img src=images/cards/"; echo $_SESSION['dcolor4']; echo "/"; echo $_SESSION['dcard4']; echo ".gif width=71 height=96>"; echo " "; }?></span> </div> </td> <td colspan=10 valign=top> <center> <b>Your Cards <? if ($_SESSION['bet']){ echo "- You have $total"; } ?></b><br> <br> <img src="images/cards/<?php if ((isset($_SESSION['card1'])) && (isset($_SESSION['show']))) { echo $_SESSION['color1']; }else{ echo "cardback";} echo "/"; if ((isset($_SESSION['card1'])) && (isset($_SESSION['show']))) { echo $_SESSION['card1']; }else{ echo "cardback";}?>.gif" width="93" height="120"> <img src="images/cards/<?php if ((isset($_SESSION['card2'])) && (isset($_SESSION['show']))) { echo $_SESSION['color2']; }else{ echo "cardback";} ?>/<?php if ((isset($_SESSION['card2'])) && (isset($_SESSION['show']))){ echo $_SESSION['card2']; }else{ echo "cardback"; }?>.gif" width="93" height="120"> <?php if ((isset($_SESSION['card3'])) && (isset($_SESSION['show']))) { echo "<img src=images/cards/"; echo $_SESSION['color3']; echo "/"; echo $_SESSION['card3']; echo ".gif width=93 height=120>"; echo " "; } if (isset($_SESSION['card4'])) { echo "<img src=images/cards/"; echo $_SESSION['color4']; echo "/"; echo $_SESSION['card4']; echo ".gif width=93 height=120>"; echo " "; } if (isset($_SESSION['card5'])) { echo "<img src=images/cards/"; echo $_SESSION['color5']; echo "/"; echo $_SESSION['card5']; echo ".gif width=93 height=120>"; echo " "; } if (isset($_SESSION['card6'])) { echo "<img src=images/cards/"; echo $_SESSION['color6']; echo "/"; echo $_SESSION['card6']; echo ".gif width=93 height=120></div></td>"; echo " "; }?> </div><br></td> </tr> <tr class=text> <td width=50% align=center> <form name="form2" method="post" action="<?php $_SERVER['PHP_SELF'] ?>"> <div align="right"> <br> <input type="submit" class="button" name="submit" value=" Hit "> <input name="hit" type="hidden" value="you hit"> </div> </form></td><td width=50% colspan=10> <form name="form4" method="post" action="<?php $_SERVER['PHP_SELF'] ?>"> <br><input type="submit" class="button" name="submit2" value="Stand" /> <input name="stand" type="hidden" value="you stand" /> </form> <?php } if (!isset($_SESSION['bet'])){ echo" <SCRIPT LANGUAGE=JavaScript> document.form2.submit.disabled=true; document.form4.submit2.disabled=true; </script>"; }?> </td> </tr> </table> </table> <br> <table width="25%" align="center" border="0" cellpadding="0" cellspacing="0" class="table"> <tr class="thinline"> <td class='header'>Blackjack Stats</td> </tr><tr><td align=center> <?php if ($bjowner == "0"){ echo "This Blackjack table is not owned by anyone<br>The max bet is set at £".makecomma($bjmaxbet).""; }else{ echo "This Blackjack table is owned by <a href='profile.php?viewuser=$bjowner'><b>$bjowner</b></a><br>The max bet is set at £".makecomma($bjmaxbet).""; } ?></td></tr></table> <? include_once"footer_bottom.php"; ?> </body> </html> <? } ?>
×
×
  • Create New...