Registration e-mail verification

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Registration e-mail verification

davidbuck
I want to implement a mechanism where someone can register for an
account on a Seaside web site by providing an e-mail address.  In order
for the registration to be completed, Seaside will send them an e-mail
containing a link which they have to click on to return to the web site
to continue the registration process.

Sending the e-mail isn't a problem.  How can I generate the URL in
advance to put into the e-mail that the user can click on to complete
the registration process?

Thanks
David Buck


_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

RE: Registration e-mail verification

Boris Popov, DeepCove Labs (SNN)
Dave,

It sounds like you're thinking about generating a URL to a callback that
will activate an account, but a safer thing to do would be to disconnect
the email from your session by doing something like,

1. On account store unique activation key
2. On your root component implement

initialRequest: aRequest
 super initialRequest: aRequest.
 aRequest
  at: 'activate'
  ifPresent: [:acc |
      aRequest
       at: 'with'
       ifPresent: [:key | "activate acc with key"].

3. Then email URLs of form,

http://www.myapp.com/online?activate=1234&with=567890

Hope this helps,

-Boris

--
+1.604.689.0322
DeepCove Labs Ltd.
4th floor 595 Howe Street
Vancouver, Canada V6C 2T5
http://tinyurl.com/r7uw4

[hidden email]

CONFIDENTIALITY NOTICE

This email is intended only for the persons named in the message
header. Unless otherwise indicated, it contains information that is
private and confidential. If you have received it in error, please
notify the sender and delete the entire message including any
attachments.

Thank you.
> -----Original Message-----
> From: [hidden email] [mailto:seaside-
> [hidden email]] On Behalf Of David Buck
> Sent: Friday, March 21, 2008 7:17 PM
> To: Seaside - general discussion
> Subject: [Seaside] Registration e-mail verification
>
> I want to implement a mechanism where someone can register for an
> account on a Seaside web site by providing an e-mail address.  In
order
> for the registration to be completed, Seaside will send them an e-mail
> containing a link which they have to click on to return to the web
site

> to continue the registration process.
>
> Sending the e-mail isn't a problem.  How can I generate the URL in
> advance to put into the e-mail that the user can click on to complete
> the registration process?
>
> Thanks
> David Buck
>
>
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Registration e-mail verification

Lukas Renggli
In reply to this post by davidbuck
>  Sending the e-mail isn't a problem.  How can I generate the URL in
>  advance to put into the e-mail that the user can click on to complete
>  the registration process?

Extracted from code used in industry:

        | account |
        account := self collectAccountInformation.
        Continuation currentDo: [ :cc |
                self sendOutMailWithUrl: (self session actionUrlForContinuation: cc)
                ^ self displayInstructionToCheckMail: account ].
        self displayConfirmation: account activate

Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Registration e-mail verification

Paolo Bonzini-2

> Extracted from code used in industry:
>
> | account |
> account := self collectAccountInformation.
> Continuation currentDo: [ :cc |
> self sendOutMailWithUrl: (self session actionUrlForContinuation: cc)
> ^ self displayInstructionToCheckMail: account ].
>         self displayConfirmation: account activate

Cute.

Does this work if the session expires (e.g. if the user does not have
his e-mail handy because of firewalls, and didn't expect having to check
his e-mail)?

Paolo
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Re: Registration e-mail verification

Lukas Renggli
> Cute.
>
>  Does this work if the session expires (e.g. if the user does not have
>  his e-mail handy because of firewalls, and didn't expect having to check
>  his e-mail)?

No, the URL is invalid after the session expires. One thing what you
could do, is to temporarily increase the session timeout to a couple
of days, while waiting for the confirmation.

Cheers,
Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside