User Registeratoin with verification

This forum is where we'll mirror posts that are of value to the community so they may be more easily found.
Post Reply
User avatar
mazhar
Master Yoda
Master Yoda
Posts: 5084
Joined: Wed Jul 09, 2008 8:21 am
Contact:

User Registeratoin with verification

Post by mazhar » Thu Oct 16, 2008 10:55 am

There may be situations when you want to be sure that the user name(Email Address) provided by the customer during the registration is valid. I have seen some posts around the forums and when answering some of these post for a solution I found that this could be easily done in AbleCommerce. The adopted solution is as below.

Solution:
When a new user comes to the store and try to register, instead of making him login after registration just make the user disable, generate a verification code and put it in the user settings. Then using the user's UserId and Verification code create a URL and send this URL in an Email to the customer's Email address and ask him to follow the URL sent to him. If the customer follows the link and reaches to your desired page, get the UserId and verification code from the URL. Now using that user id load the user and match the verification code you get from the URL with the verification code in that user's settings. If both are same just approve the user and ask him to login.

This technique will made it possible that all users have the proper Email address and you can contact them. You can also write your clean up service which may remove those users who did not verified their accounts within a specified amount of time.

I thought it would be better to implement the basic stuff my self and so i did. You can download the attachment and install it in the same order as its directory structure. Almost all basic functionality is done. Most probably you will need to change the Email alert contents or the messages which are being shown at registration or on the verification completion page.

Email Settings
When sending the Email AbleCommerce code is used. So if you have configured the Email settings properly it will work. The Email alerts make use of default from address so please don't forget to specify the Default From address in Email settings.
Last edited by mazhar on Mon Oct 20, 2008 10:41 am, edited 1 time in total.

keats76
Commander (CMDR)
Commander (CMDR)
Posts: 117
Joined: Sat Dec 15, 2007 4:45 pm

Re: User Registeratoin with verification

Post by keats76 » Fri Oct 17, 2008 3:24 pm

I'm curious, have you had any problems where your validation URL fails? I implemented something similar a little while back, but I ended up scrapping it. Some email clients were breaking up my verification URL. When the user would go to validate their registration, the userid (email address) was, at times, incomplete. This caused me all sorts of headaches.

Not all email clients had this problem. I think the Outlook folks were OK. Just make sure to keep the length of your URL in mind when implementing this type of solution.

I may revisit it again if your solution is more effective.

User avatar
mazhar
Master Yoda
Master Yoda
Posts: 5084
Joined: Wed Jul 09, 2008 8:21 am
Contact:

Re: User Registeratoin with verification

Post by mazhar » Sat Oct 18, 2008 6:50 am

Well I checked it with Thunderbird and it worked fine. The code above is for the sake to give some base idea that how this could be done. Most probably different stores could have different verification code schemes and can keep this type of constraints in mind when generating the verification code.

Could you list the Email client which had problem?

AnthonyD
Ensign (ENS)
Ensign (ENS)
Posts: 20
Joined: Mon Jun 07, 2010 12:50 am

Re: User Registeratoin with verification

Post by AnthonyD » Wed Oct 27, 2010 12:36 am

I implemented the download file but I find the following error message:

[[ConLib:RegisterDialog]] ...\ConLib\RegisterDialog.ascx.cs(48): error CS1501: No overload for method 'CreateUser' takes '7' arguments

Worse still, when I replaced the original files back, they won't work anymore. I badly need help.

Thanks and regards.

User avatar
crockettdunn
Lieutenant Commander (LCDR)
Lieutenant Commander (LCDR)
Posts: 105
Joined: Sun Oct 26, 2008 6:32 pm
Contact:

Re: User Registration with verification

Post by crockettdunn » Thu Aug 06, 2015 8:33 am

I would like to know if there are any major differences between the logic in this code and the logic used in the GOLD email list signup with verification. I just gave a developer the code from this post to implement a user registration email verification, and then I noticed the "Email List Signup With Verification" product template and wondered if that code might be better.

thanks.

Post Reply