Bradley99 Posted January 28, 2011 Share Posted January 28, 2011 Hey guys, I'm trying to create a my properties page so a user can control their properties from one page. At the minute they have to be in the country they own the property, then click on say Slots to be able to view the CP. I have a casino CP and bulletfactory CP but simply putting these scripts into the one page won't work. It has no reference as to why you have to be in the actual country to view the CP in the code? Here's the some of the Slots code: (Alls i see is the Include CasinoCP.php? <?php session_start(); include_once "includes/functions.php"; include_once "click_limit.php"; include "includes/jail_check.php"; logincheck(); $username=$_SESSION['username']; include_once "includes/db_connect.php"; include_once"casinoCP.php"; echo "$style"; $input="Slots"; $fetch= mysql_fetch_object(mysql_query("SELECT * FROM users WHERE username='$username'")); $slots = mysql_fetch_object(mysql_query("SELECT * FROM casinos WHERE location='$fetch->location' AND casino='Slots'")); $fetch_owner=mysql_fetch_object(mysql_query("SELECT * FROM users WHERE username='$slots->owner'")); $ownerrr= $slots->owner ; if($ownerrr == "0"){ if (isset($_POST['buyit'])){ if($fetch->money >= 500000){ $m=$fetch->money-500000; echo "You bought the slot table!"; mysql_query("UPDATE casinos SET owner='$fetch->username' WHERE location='$fetch->location' AND casino='Slots'"); mysql_query("UPDATE users SET money='$m' WHERE username='$fetch->username'"); }else{ echo "You do not have enough money."; } } echo " <form name='formm' method='post' action='slots.php'> <center><table cellspacing=0 cellpadding=0 align=center border=1 bordercolor=black class=thinline><tr><td class=tableheading align=center>Slots $fetch->location</td></tr> <tr align=center><td class=tablearea>This slot table has no owner. You can buy it for 500.000</td></tr> <tr align=center><td class=tablearea><input name='buyit' type='submit' class='button' value=' Buy it ' /></td></tr> </table> </form>"; exit(); Link to comment https://forums.phpfreaks.com/topic/226006-cp-help/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.