kcmajor36 Posted June 2, 2010 Posted June 2, 2010 Okay first replace your register.php with: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Then name this one activation_cron.php You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Then add this to you SQL: [mysql]CREATE TABLE `confirm` ( `user` INT( 11 ) NOT NULL , `code` BIGINT( 40 ) NOT NULL ) ENGINE = MYISAM ; ALTER TABLE users ADD `confirmed` int(11) NOT NULL ; UPDATE users SET confirmed=1[/mysql] Then last but not least, add this to your cron jobs as a two hour cron: 0 */2 * * * * curl http://yourgameurl.com/activation_cron.php?code=713518314 Quote
kcmajor36 Posted June 2, 2010 Author Posted June 2, 2010 One word: Insecure If theres a problem then post a fix on here! Quote
Brad Posted June 2, 2010 Posted June 2, 2010 I like it but not secure kyle good for your first mod +1 Quote
kcmajor36 Posted June 2, 2010 Author Posted June 2, 2010 If you guys could help me secure it that would be great! Quote
Danny696 Posted June 2, 2010 Posted June 2, 2010 Problem $IP = ($_SERVER['HTTP_X_FORWARDED_FOR']) ? $_SERVER['HTTP_X_FORWARDED_FOR'] : $_SERVER['REMOTE_ADDR']; Fix $IP = $_SERVER['REMOTE_ADDR]; Quote
Danny696 Posted June 2, 2010 Posted June 2, 2010 Woops, should be $IP = $_SERVER['REMOTE_ADDR']; Quote
Danny696 Posted June 2, 2010 Posted June 2, 2010 Fixed errors, unless your on php 5.3.1 (ties in with next part ;)) and still insecure $IP = ($_SERVER['HTTP_X_FORWARDED_FOR']) ? $_SERVER['HTTP_X_FORWARDED_FOR'] :$_SERVER['REMOTE_ADDR']; Quote
kcmajor36 Posted June 2, 2010 Author Posted June 2, 2010 and it shows an error every time I put that in there so if you want to fix it your self and post the WHOLE code then that would be great! Quote
Djkanna Posted June 2, 2010 Posted June 2, 2010 ereg() eregi() are deprecated now (and I think removed as of PHP 6.0) preg_match() preg_replace() Are your better options :) EDIT: Didn't see RulerOfZu's post O.o Quote
Danny696 Posted June 2, 2010 Posted June 2, 2010 How hard can it be to replace the whole of $IP = ($_SERVER['HTTP_X_FORWARDED_FOR']) ? $_SERVER['HTTP_X_FORWARDED_FOR'] :$_SERVER['REMOTE_ADDR']; with $IP = $_SERVER['REMOTE_ADDR']; Quote
kcmajor36 Posted June 2, 2010 Author Posted June 2, 2010 Thats to difficalt could you post the code with them in it? Quote
kcmajor36 Posted June 2, 2010 Author Posted June 2, 2010 How hard can it be to replace the whole of $IP = ($_SERVER['HTTP_X_FORWARDED_FOR']) ? $_SERVER['HTTP_X_FORWARDED_FOR'] :$_SERVER['REMOTE_ADDR']; with $IP = $_SERVER['REMOTE_ADDR']; Oh I get it now! ;) Sorry Quote
rulerofzu Posted June 2, 2010 Posted June 2, 2010 The whole email check function was posted on a linux forum back in 2007 May interest you to find that it was updated to the following. Not tested it though. You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Quote
bladewolf2010 Posted June 2, 2010 Posted June 2, 2010 Can't really call a script you got from google yours :) Quote
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.