Jump to content
MakeWebGames

Djkanna

Members
  • Posts

    3,137
  • Joined

  • Last visited

  • Days Won

    35

Everything posted by Djkanna

  1. Djkanna

    Can someone help me?

    Try this: <?php session_start(); if(get_magic_quotes_gpc() == 0) { foreach($_POST as $k => $v) { $_POST[$k]=addslashes($v); } foreach($_GET as $k => $v) { $_GET[$k]=addslashes($v); } } switch($_GET['do']){ case 'auth': auth(); break; default: index(); break; } function index(){ print '<table width="100%" cellspacing="1" cellpadding="1" style="text-align:center;"><tr><th>Login to Hardcore Mafia</th></tr> <form action="index.php?do=auth" method="post"> <tr><td> Username:<input type="text" name="username"></td></tr> <tr><td> Password:<input type="password" name="password"></td></tr> <tr><td> <input type="submit" value="Login!"></td></tr> </form> </table>'; } function auth(){ $host="*Blanked out*"; $user="*Blanked out*"; $pass="*Blanked out*"; $database="*blanked out*"; $cid = mysql_connect($host,$user,$pass) or die(mysql_error()); mysql_select_db($database,$cid) or die(mysql_error()); if($_POST['username']=="" || $_POST['password']==""){ die("Please Fill in All Fields"); } $userdata = mysql_query("SELECT * FROM users WHERE username='{$_POST['username']}' AND password='{$_POST['password']}'") or die(mysql_error()); if(mysql_num_rows($userdata)==0){ die("Invalid Login!"); } else{ $_SESSION['loggedin']=1; $fetch = mysql_fetch_array($userdata); $_SESSION['mobid'] = $fetch['userid']; header("Location: loggedin.php"); } } ?>
  2. Djkanna

    Can someone help me?

    Have you changed the file (index.php) to use $_SESSION['mobid'] rather than $_SESSION['userid']?
  3. That's awesome thanks Wrx
  4. Djkanna

    Can someone help me?

    No problem, It had been said previously ;) Reek13: First time ever :O
  5. Oh No! The only problem with these mods is they hate me I bet if I played guess the wire I'd get blown up all the fippin' time -.- Nice job VirtualShogun.
  6. Djkanna

    Can someone help me?

    <?php session_start(); if(get_magic_quotes_gpc() == 0) { foreach($_POST as $k => $v) { $_POST[$k]=addslashes($v); } foreach($_GET as $k => $v) { $_GET[$k]=addslashes($v); } } switch($_GET['do']){ case 'auth': auth(); break; default: index(); break; } function index(){ print '<table width="100%" cellspacing="1" cellpadding="1" style="text-align:center;"><tr><th>Login to Hardcore Mafia</th></tr> <form action="index.php?do=auth" method="post"> <tr><td> Username:<input type="text" name="username"></td></tr> <tr><td> Password:<input type="password" name="password"></td></tr> <tr><td> <input type="submit" value="Login!"></td></tr> </form> </table>'; } function auth(){ $host="*Blanked out*"; $user="*Blanked out*"; $pass="*Blanked out*"; $database="*blanked out*"; $cid = mysql_connect($host,$user,$pass) or die(mysql_error()); mysql_select_db($database,$cid) or die(mysql_error()); if($_POST['username']=="" || $_POST['password']==""){ die("Please Fill in All Fields"); } $userdata = mysql_query("SELECT * FROM users WHERE username='{$_POST['username']}' AND password='{$_POST['password']}'") or die(mysql_error()); if(mysql_num_rows($userdata)==0){ die("Invalid Login!"); } else{ $_SESSION['loggedin']=1; $fetch = mysql_fetch_array($userdata); $_SESSION['userid'] = $fetch['userid']; header("Location: loggedin.php"); } } ?> Try that.
  7. /me pops up and says "You have mail!" Good job Coly010
  8. Looks good bud, well done. On a side note: I dreamed a dream in time gone by Hehe
  9. Meh lemme work on a rough idea... Right: How about multiplying the number by ten to start. Then dividing it by 500 for nonD's And divide it by 200 for Don's Max energy = 13 *10 = 130 130/500 = 0.26 130/200 = 0.65 *10/500 = nonD's *10/200 = Don's Seems releativly evil to me but it will keep training ect down so no one person ahead and others having no chance of catching up. ==TBC==
  10. Djkanna

    Right Menu

    Epic fail wasn't directed at you it was directed at the idiot that posted the formentioned phail originally ;) $IP variable ;)
  11. Meh I'll stop doing it then (saves me the trouble) lol Um I think the ref in register still applies. Same with the IP, Does lite come with a forum? CreateGang/gangs in general Admin panel obviously ... There will be more. But I've got no clue
  12. Djkanna

    Right Menu

    No epic phail. I'll have a look when I get some free time ;)
  13. Argh, Why the '@' operator??!? Come on Danny don't you think if there was no globals.php file the game wouldn't work so you wouldn't be able to sign in, so you wouldn't be available to use the inventory so your script wouldn't work so it wouldn't need the @ there anyway.. Inconclusion: @ = useless ;) Other than that good job buddy Meh EDIT: Thanks to Nickson (pointed out that you use it elsewhere also) I didn't notice this so the above applies to the operator on the include ;)
  14. Djkanna

    Traffic

    Second one get's my vote Nice idea Mdshare.
  15. Stop using those words together... It's been out what three years it's just an excuse for it not to be updated call it "a BETA version".
  16. Bah, my least favourite games (hidden object) I always get all but one object then give up -.- :P Looks good :)
  17. [mysql]Query was UPDATE users SET admin=1 WHERE userid=[/mysql] I'm going to assume $userid isn't there or isn't defined.
  18. Welcome back bud, no I don't know who you are but hey and welcome back ;)
  19. My bad didn't read -.-
  20. That's actually a nice way to go about it :) Next time make sense... :P
  21. Um the designs okay but I'm pretty sure it isn't supposed to look like that.
  22. Top Five Bands(or artists): 1: Willie Nelson 2: Metallica 3: Johnny Cash 4: John Lennon 5: Santana Top Five Songs: 1: Seven Spanish Angels - Willie Nelson and Ray Charles 2: Blue Eyes Crying In The Rain - Willie Nelson 3: Nothing Else Matters - Metallica 4: Unforgiven - Metallica 5: Hurt - Johnny Cash Soo many more! ... :)
  23. ALTER TABLE `users` ADD `loan` INT (11) NOT NULL in PhpMyAdmin
  24. I guess I'm the only one that found it old and not funny then?!?
  25. Djkanna

    help

    Hi Nodaska, You will find it in MakeWebGame's Download Database (Scripts Vault) Here's the link: Mc Codes Lite
×
×
  • Create New...