Jump to content
MakeWebGames

NationGamer

Members
  • Posts

    60
  • Joined

  • Last visited

Everything posted by NationGamer

  1. Thanks added and screenshots added soon
  2. This Mod is currently under development i will post screen shot and code up within next 2 days Files Includes: 2 php files 2 Mysql databases User Features: Can Create Tickets Priority Selection Close Tickets Attach a image e.g screenshot Recieve Event when replied to Staff Features: Open/Close Tickets Reply To Open Tickets Attach Images e.g image showing user what to do   anyone have any suggestions to make this modification better please feel free to post below
  3. thanks man worked like a charm i tried something like that but i think i left the session_start(); code out and obviously quite important lol
  4. well the problem is im trying to make login page reconize the current session so like if users is logged in then when they visit the login page or signup they get redirect strait back to the main index page i have tried a couple things but none seem to work could someone pease help me with this and possibly show me how to do this thanks.
  5. could someone look through the sql at the top and tell me if it is correct and the way the ranks are called from the sql thanks BTW not my staff list just using this one before i change my staff list   <?php include "globals.php"; $staff=array(); $q=$db->query("SELECT u.*,s.*,c.* FROM users u LEFT JOIN staff_users s ON u.userid=s.id LEFT JOIN gangs c ON u.gang=c.gangID ORDER BY userid ASC"); while($r=$db->fetch_row($q)) { $staff[$r['userid']]=$r; } echo"<table width=100% border=1 style=text-align:center; class=table>"; print " <h2 style='padding-top:10px;'> Staff List</h2></div> [b]Admins[/b] <table width=80% border=1 style=text-align:center; class=table><tr style='background:gray'><th>User</th> <th>Duties</th> <th>Level</th> <th>Money</th> <th>Last Seen</th> <th>Status</th> </tr>"; foreach($staff as $r) { if($r['rank']==Admin) { if ($r['gangPREF'] != "") { $gangtag = "[url='gangs.php?action=view&ID={$r['][{$r['gangPREF']}][/url]"; } else { $gangtag = ""; } if($r['laston'] >= time()-15*60) { $on="<font color=green>[b]Online[/b]</font>"; } else { $on="<font color=red>[b]Offline[/b]</font>"; } print "<tr> <td>[url='viewuser.php?u={$r[']{$r['username']}[/url] [{$r['userid']}]</td> <td> {$r['duties']}</td> <td>{$r['level']}</td> <td>\${$r ['money']}</td> <td>".date('F j, Y, g:i:s a',$r['laston'])."</td> <td>$on</td> </tr>"; } } print "</table>"; print "[b]Secretaries[/b] <table width=80% border=1 style=text-align:center; class=table><tr style='background:gray'><th>User</th> <th>Duties</th> <th>Level</th> <th>Money</th> <th>Last Seen</th> <th>Status</th> </tr>"; foreach($staff as $r) { if($r['rank']==GM) { if ($r['gangPREF'] != "") { $gangtag = "[url='gangs.php?action=view&ID={$r['][{$r['gangPREF']}][/url]"; } else { $gangtag = ""; } if($r['laston'] >= time()-15*60) { $on="<font color=green>[b]Online[/b]</font>"; } else { $on="<font color=red>[b]Offline[/b]</font>"; } print "<tr> <td>[url='viewuser.php?u={$r[']{$r['username']}[/url] [{$r['userid']}]</td> <td> {$r['duties']}</td> <td>{$r['level']}</td> <td>\${$r ['money']}</td> <td>".date('F j, Y, g:i:s a',$r['laston'])."</td> <td>$on</td> </tr>"; } } print "</table>"; print "[b]Assistants[/b] <table width=80% border=1 style=text-align:center; class=table><tr style='background:gray'><th>User</th> <th>Duties</th> <th>Level</th> <th>Money</th> <th>Last Seen</th> <th>Status</th> </tr>"; foreach($staff as $r) { if($r['rank']==FM) { if ($r['gangPREF'] != "") { $gangtag = "[url='gangs.php?action=view&ID={$r['][{$r['gangPREF']}][/url]"; } else { $gangtag = ""; } if($r['laston'] >= time()-15*60) { $on="<font color=green>[b]Online[/b]</font>"; } else { $on="<font color=red>[b]Offline[/b]</font>"; } print "<tr> <td>[url='viewuser.php?u={$r[']{$r['username']}[/url] [{$r['userid']}]</td> <td> {$r['duties']}</td> <td>{$r['level']}</td> <td>\${$r ['money']}</td> <td>".date('F j, Y, g:i:s a',$r['laston'])."</td> <td>$on</td> </tr>"; } } print "</table></div><div></div> </div></div></div></div></div>"; $h->endpage(); ?>
  6. firstly im trying to make 1 page work within the inside and outside of the game and header ive made for outside the game aswell as inside as all the outside all take the same style so made sense to make a new header for that
  7. yes i did but i removed that check when i first created it
  8. still doing the same as before it is only showing 1 style when loggedin it shows the page but when i logout it dont show the out header it just redirects back to the loggin page like it is only showing the inside globals
  9. how else would i do this without the IF statement as i have made an outside globals called main_globals.php and that includes the outside styles as i was saying i need to check if user is loggedin or out so the page shows the correct style for the page so if loggedin ==0 then outside style and loggedin==1 inside style of the game the only way i would know of doing this is the way ive done it checking to see if the loggedin session is there as some pages i want to use inside and outside the game e.g forums , tos, contact so i need to find a way for it to check if they loggedin then pull the style from inside or outside the game
  10. i am currently making an outter header for my game and have hit a stop in it that i can figure out with 1 page i want to use in game and outgame so the part i use is if($_SESSION['loggedin']==1) { include "globals.php"; } elseif($_SESSION['loggedin']==0) { include "main_globals.php"; } i am putting this at the top of the page i want to work in game and out game but it only seems to work with ingame ive tried doing this loads dif ways like just putting else and tried it removing the else so it just the if statement could someone please help me with this please
×
×
  • Create New...