Skip to main content
Known Participant
September 14, 2007
Question

How can i confirm an email address?

  • September 14, 2007
  • 3 replies
  • 686 views
Hi!

When users register for my site, i'd like to send an email confirmation to the users email address so that the user can confirm that the email address supplied is correct.

How can i do this?

Thanks all!
This topic has been closed for replies.

3 replies

Inspiring
September 17, 2007
peewee_larkin wrote:
> Hi!
>
> When users register for my site, i'd like to send an email confirmation to the
> users email address so that the user can confirm that the email address
> supplied is correct.
>
> How can i do this?
>
> Thanks all!
>

basic thing i would do is:
let the user register (fill out registration form)
store user's reg info in a db with some field like "confirmed" set to false
send user an email with confirmation, login details and a link to
"confirm subscription" page with some user identifier in the link (i.e.
db record id or cf uuid)
depending on what kind of unique id your link uses:
- if a link is easily guessable (i.e. you use db record id): on the
"confirm subscription" page query the db based on some id in the link
you sent the user and ask him to re-enter his email -> if the entered
email matches stored email set 'confirmed' field in db to true and
display your 'thank you...' message
- if a link is a strong one (i.e. if you use cf uuid): just query db for
user info based on that uuid and set 'confirmed' to true, then say your
'thank you...'

hth
--

Azadi Saryev
Sabai-dee.com
http://www.sabai-dee.com
BKBK
Community Expert
September 14, 2007
When users register for my site, i'd like to send an email confirmation to the users email address so that the user can confirm that the email address supplied is correct.

No, it is not to confirm the validity of the e-mail address. It is to confirm to the user that he has successfully registered. You might want to mention how glad you are to get his custom and to remind him of the unique benefits you offer. Also, you would usually include the information he needs to log in. You have to assume that he receives a hundred e-mails like yours everyday.



Inspiring
September 14, 2007
With cfmail. Details are in the cfml reference manual. If you don't have one, the internet does.