djfox Posted February 4, 2008 Share Posted February 4, 2008 I`m building a mini-game using php where there is a score involved. It will use forms to send the information along. Thus far, forms I`ve seen (and used) show the url as things like game.php?id=8&s=1000 Anything I can do to keep people from being able to just type in things in the url bar to cheat the code? Quote Link to comment Share on other sites More sharing options...
Tak Posted February 4, 2008 Share Posted February 4, 2008 One thing that you can do is use the POST method instead of GET. Then the information isn't passed along via the URL. Quote Link to comment Share on other sites More sharing options...
ratcateme Posted February 4, 2008 Share Posted February 4, 2008 why don't you use SESSION to store all the information like scores so people cant cheat at all Scott. Quote Link to comment Share on other sites More sharing options...
djfox Posted February 4, 2008 Author Share Posted February 4, 2008 why don't you use SESSION to store all the information like scores so people cant cheat at all Scott. Because the form url could be changed to cheat the code. One thing that you can do is use the POST method instead of GET. Then the information isn't passed along via the URL. Thanks, I`ll give that a shot. Quote Link to comment Share on other sites More sharing options...
helraizer Posted February 4, 2008 Share Posted February 4, 2008 About SESSION he means like $_SESSION['s'] = 1000 That way no one can edit it and thus no one can cheat. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.