View Single Post
  #13 (permalink)  
Old 05-18-2007, 06:39 AM
dollars5's Avatar
dollars5 dollars5 is offline
Pligg is my love :)
 
Join Date: Dec 2006
Location: India
Posts: 2,154
Thanks: 290
Thanked 266 Times in 177 Posts
The captcha and e-mail validation code for others also to use (same as the one posted for Ash in dev notes - it is different from the previous single step registration code)

the new code is packed below - contains the files that requires changes:
1] login.php - reads a new GET Value ($_GET[result]) for displaying activated or failed to activate user
2] register.php - modified do_register1() to save last login IP, time to 0 and send a validation e-mail with high-priority instead of going to step 2 captcha validation
3] validation.php - new file to perform user activation and forward to Login.php to display the activation result
4] /better_captcha_fonts - 8 free fonts that are bold and clear on any type of device (I chose fonts that wil display good on mobiles as well like Blackberry and Treos) - users are free to replace with any fonts of their choice to create weirdness in the characters and free to use as many fonts as they want - but needs to name with numbers.
5] /libs/login.php - changed the Authenticate() to validate $user->user_lastlogin > 0 as during registration we set this to 0.
6] /libs/ts.php - getCaptchaCode to leave O and 0 (should also edit the 1 and L and I as they cause problems), ts_gfx() to generate a large clear and readable captcha and other related functions.
7] /templates/yget/register_step_1.tpl - to display the captcha in step 1 itself.

Hope this helps - should you need any further details - I can help. The code is packed in the attachment http://forums.pligg.com/attachment.p...1&d=1180336202

But Ash is sure to get a even better version of it.

Last edited by dollars5; 05-28-2007 at 03:10 AM..
Reply With Quote
The Following 2 Users Say Thank You to dollars5 For This Useful Post: