pomegranstudios Posted September 14, 2010 Share Posted September 14, 2010 Hello all..... Grasshopper here......... Need help with the following: I have a registration form for a Sport Gym Complex offering a free guest pass if you register...... Where would I implement cookies or sessions to reject 2nd times registrants trying to take advantage of the free guest pass within the year; I have attached the php.file Thanks Steve [attachment deleted by admin] Quote Link to comment Share on other sites More sharing options...
coupe-r Posted September 14, 2010 Share Posted September 14, 2010 I'm not sure cookies or sessions come into place here. What you want is to not let the same person register more than once. The only thing you can do is log their IP, username, first / last name, email, and all the other goodies. Then, when someone registers, check the DB for ALL of that info to see if it matches. If it matches, reject. Quote Link to comment Share on other sites More sharing options...
pomegranstudios Posted September 14, 2010 Author Share Posted September 14, 2010 That is exactly what I need. Any suggestions on How To? Much appreciative..... Thank you steve Quote Link to comment Share on other sites More sharing options...
coupe-r Posted September 14, 2010 Share Posted September 14, 2010 Sure.. Capture every piece of data you can on the user (IP Address, name, email, etc). Now you have 1 record. Lets say they try to register again. when they fill out your form again, check the field vars against the record in your DB, especially the IP address. Now, you can't just query again the name, because that is too common, you would need to do IP address, email, last name, or any other unique data you can pull. Now, this is not full proof because they can switch computers (different IP address), use a different email address, etc. You can ever ask for a phone number and query on that as well. I've never done something like this, but I would start here and continue to build out. Does this make sense? Quote Link to comment Share on other sites More sharing options...
plznty Posted September 14, 2010 Share Posted September 14, 2010 Cookies could be deleted and sessions would just go. You will need to log ip and then only allow ip's that are not in your database. Quote Link to comment Share on other sites More sharing options...
chintansshah Posted September 14, 2010 Share Posted September 14, 2010 Hi, This is a very typical problem and I am sure you will get 5-10% junky registrations. 1. You cannot compare ip, because in organisational level mutiple pcs have single out-ip, so after very first registration others people stopped to say "already register" 2. People can use multiple email 3. People can use multiple phone numbers. The idle solutions is, after registration ask user's mobile number and send a "temp code" in SMS, which user should entered on the screen after received SMS. So, you can check if code entered correctly then you approved that user. Quote Link to comment Share on other sites More sharing options...
Rifts Posted September 14, 2010 Share Posted September 14, 2010 Hi, This is a very typical problem and I am sure you will get 5-10% junky registrations. 1. You cannot compare ip, because in organisational level mutiple pcs have single out-ip, so after very first registration others people stopped to say "already register" 2. People can use multiple email 3. People can use multiple phone numbers. The idle solutions is, after registration ask user's mobile number and send a "temp code" in SMS, which user should entered on the screen after received SMS. So, you can check if code entered correctly then you approved that user. Can you elaborate on this? How would you even begin to do this with php? Quote Link to comment Share on other sites More sharing options...
chintansshah Posted September 14, 2010 Share Posted September 14, 2010 Create one form with following elements 1. Name 2. Email 3. Mobile 4. Save(button) After filling, user will submit the form at same time you send a SMS with random text-code(like T30SEP, etc....) to that cell number via SMS gateways... that random code should be linked with data which user has inserted. After received a SMS, user should insert a code to text box at that time you should check if entered txt is same what you have sent, if correct then you approved that user for free passes.... Quote Link to comment Share on other sites More sharing options...
Rifts Posted September 14, 2010 Share Posted September 14, 2010 That sounds really cool, how would you go about sending the SMS though? 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.