Lost Password?


Go Back   CodeCall Programming Forum > Web Development Forum > PHP Forum

PHP Forum Use this forum to discuss all aspects of PHP Development. PHP is a server-side, cross-platform, HTML embedded scripting language that lets you create dynamic web pages.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 11-28-2006, 10:34 PM
Lop's Avatar   
Lop Lop is offline
Speaks fluent binary
 
Join Date: May 2006
Posts: 1,149
Rep Power: 18
Lop will become famous soon enoughLop will become famous soon enough
Default Email Verification

I've created the anti spam image from the help of you guys:

http://forum.codecall.net/php/1536-n...generator.html


Now, how do I go about creating a verification email with all kinds of wierd characters and symbols at the end like you receive from these forums and everywhere else you sign up?
__________________
Lop
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Sponsored Links
  #2 (permalink)  
Old 11-29-2006, 04:42 PM
doodlebug doodlebug is offline
Newbie
 
Join Date: Nov 2006
Posts: 1
Rep Power: 0
doodlebug is on a distinguished road
Default

Came accross this a couple of days ago might be worth considering:

http://www.howtocreate.co.uk/php/emailtools.php - demo

http://www.howtocreate.co.uk/php/dnl...ile=4&action=0 - download
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 11-29-2006, 04:53 PM
John's Avatar   
John John is offline
Co-Administrator
 
Join Date: Jul 2006
Age: 20
Posts: 3,433
Last Blog:
Google Web Toolkit
Rep Power: 20
John has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond repute
Send a message via AIM to John Send a message via MSN to John
Default

After thinking about it for a few minutes I came up with an idea, but im not sure its the same way the forums do it. I dont have any smaple code but ill walk you through what i would do.

1) Create a random function that generates a random string say 20 characters long and returns the value.

2) When the user registers, have the unique string generated and pared with the user in the database. Maybe I would setup the database like this:

users:
Code:
id     username       password             email                      valid
1      sidewinder      1235456       Sidewinder@asdf.com    12asd54f1d$ad5fd1112
where valid is the random string.

3) Auto generate the email that sends a link like:
Quote:
Click the following link to activate your account:
http://www.yourdomain.com/validate.php?name=Sidewinder&validation_number=12a sd54f1d$ad5fd1112
4) Have the validate.php script check to see if $_GET['validation_number'] is the same as the string paired with that user [Sidewinder] in the database

If it is the same, have the value of valid updated to "yes" and just make your login session checks to see if the user is valid

of course you could just create a table of queed users that are "invalid" and when they go to validate their account, the validate.php could do the stuff above and then transfer their db information to the users table that are "valid" users, that way you would have the valid column in your users table taking up extra bytes...but i think you get the general idea

just my 2 cents

Last edited by John; 11-29-2006 at 05:02 PM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 11-29-2006, 05:41 PM
John's Avatar   
John John is offline
Co-Administrator
 
Join Date: Jul 2006
Age: 20
Posts: 3,433
Last Blog:
Google Web Toolkit
Rep Power: 20
John has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond repute
Send a message via AIM to John Send a message via MSN to John
Default

Quote:
Originally Posted by doodlebug View Post
Came accross this a couple of days ago might be worth considering:

http://www.howtocreate.co.uk/php/emailtools.php - demo

http://www.howtocreate.co.uk/php/dnl...ile=4&action=0 - download
I believe thats to verify what the user inputed is an email address. If I understood correctly, he wants to make the user activate their account by clicking on a link sent to them via email.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 11-29-2006, 08:27 PM
Ronin Ronin is offline
Programming Professional
 
Join Date: Apr 2006
Posts: 299
Rep Power: 11
Ronin is on a distinguished road
Default

Sidewinder has it about the way I thought of doing it when I read this post.

Check Here


Many applications in the field of Web development need to validate email addresses. While this can be done in a variety of ways, one simple but effective way involves writing your own functions in PHP. Alejandro Gervasio explains this approach.

Within the huge and fascinating field of Web development, one of the most common tasks that many applications have to deal with is, undoubtedly, verifying whether a user email address is valid. Certainly, this should sound very familiar to most Web developers, whether they are setting up their first consciously-coded script or implementing full-blown applications required to handle more complex processes. Whatever the case, validating a visitor's email address to see if it belongs to a real domain is always a good step to help you avoid, at least partially, several possible problems that arise when applications are receiving incoming bogus data. From cluttering up databases with invalid information, to sending newsletters or similar content to email addresses at nonexistent domains, headaches are surely going to come up from receiving fake email.

Several approaches can be taken to address the problem, depending on the level of complexity desired for the validation itself. If the application is going to make use of a basic level of validation, a quick-and-dirty way to handle the situation might be to implement a simple PHP function that performs pattern matching to a standardized email address format, as we have seen many times. However, when a deeper and more complex validation is required, we should take a look at well-trusted validation classes, such as Pear’s HTML_Quick Form class, or many other validation classes widely available out there.

The third option involves writing our own set of functions for in-deep email address checking, which can be considered an intermediate solution between the two above described. This approach is versatile and portable enough to be used whether we want to expand basic validating functions or add extra functionality to existing classes.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Sponsored Links
  #6 (permalink)  
Old 12-06-2006, 08:09 AM
TkTech TkTech is offline
 
Join Date: Jun 2006
Posts: 992
Last Blog:
Having trouble with yo...
Rep Power: 20
TkTech is on a distinguished road
Send a message via MSN to TkTech
Default

Sidewinder, thats exatyl the typical model used in things such as a forum. If you go with what Sidewinder said, you wont be hard off.
__________________
CodeCall Blog | CodeCall Wiki | Shareware | Linux Forum
Chat with other CodeCall members on IRC; connect to irc.codecall.net and join #codecall
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7 (permalink)  
Old 12-21-2006, 12:15 PM
businessman332211 businessman332211 is offline
Newbie
 
Join Date: Dec 2006
Posts: 4
Rep Power: 0
businessman332211 is on a distinguished road
Default

That's called a captcha, they take a few minutes to create or you could use third party software.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #8 (permalink)  
Old 12-22-2006, 11:32 PM
John's Avatar   
John John is offline
Co-Administrator
 
Join Date: Jul 2006
Age: 20
Posts: 3,433
Last Blog:
Google Web Toolkit
Rep Power: 20
John has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond repute
Send a message via AIM to John Send a message via MSN to John
Default

Quote:
Originally Posted by businessman332211 View Post
That's called a captcha, they take a few minutes to create or you could use third party software.
A CAPTCHA is a random string of characters generated over an image, here is an earlier post that discussed that

http://forum.codecall.net/php/1536-n...generator.html
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
PHP: Validate Email Address Jordan PHP Tutorials 26 05-22-2008 01:15 PM
PHP:Tutorial - Email Verification John PHP Tutorials 3 09-19-2007 01:19 PM
Dynamic Email insertion in HTML Gibster HTML Programming 5 07-17-2007 05:22 PM
WARNING: New e-gold phishing email andrew Business and Legal 3 04-27-2007 12:54 PM
Catch All Email Account Nightracer Computer Software/OS 4 11-17-2006 06:56 PM


All times are GMT -5. The time now is 04:12 PM.

Contest Stats

WingedPanther ........ 2753.6
Xav ........ 2704
Brandon W ........ 1702.32
John ........ 1207.73
marwex89 ........ 1175.24
morefood2001 ........ 966.05
dcs ........ 655.75
Steve.L ........ 475.59
orjan ........ 418.58
Aereshaa ........ 383.54

Contest Rules

CodeCall Goal

Goal: 100,000 Posts
Complete: 98%

Ads