Community Forums

Customer Verification e-mail feature in OpenCart

Free manual modifications can be contributed here. Modifications are manual snippets of code that are pasted into the forums for others to use.

Customer Verification e-mail feature in OpenCart

Postby kafoso » Tue Mar 27, 2012 6:32 am

Why not let customers approve their own accounts through a link in a customer account verification e-mail, used by many other webshop systems and Content Management Systems?

I put together a small tutorial explaning how to do this, which you can see here: **REMOVED BECAUSE URL DOES NOT EXIST ANYMORE**
(Sorry, but I'm not going to repost the entire thing here ;) )

The idea is that webshop administrators no longer have to approve all customers in a webshop, but at the same time maintain some level of safety, which is why a Captcha validation is used plus a one-time only link sent via e-mail to the customer. This ultimately means that customers can register and start shopping during the weekend, for instance, where webshop administrators may not have time to approve customers themselves.

I hope you will find this useful and hopefully the OpenCart team will consider integrating this in a newer version.

The modifications were performed in OpenCart version 1.5.1.3.1, but should work with all versions above 1.5.

Best regards
Kafoso
kafoso
 
Posts: 3
Joined: Tue Aug 30, 2011 2:58 pm

Re: Customer Verification e-mail feature in OpenCart

Postby gabbya » Wed May 23, 2012 11:34 am

YOU ARE A STAR. :banana:
Working perfect on ver 1.5.2.X
Thank you so much


Some extra:
Change :/catalog/model/account/customer.php
$message .= $this->url->link('account/login', '', 'SSL') . "\n\n";
to:
//$message .= $this->url->link('account/login', '', 'SSL') . "\n\n"; //we do not need the login link anymore.

Go to :/catalog/language/english/account/success.php
Replace :
$_['text_approval'] = '<p>Thank you for registering with %s!</p><p>You will be notified by email once your account has been activated by the store owner.</p><p>If you have ANY questions about the operation of this online shop, please <a href="%s">contact the store owner</a>.</p>';
With:
$_['text_approval'] = '<p>Thank you for registering with %s!</p><p>An email has been sent to the email address you provide us with a link to verify your Account.</p><p>Make sure to check your email and follow the link to activate your Account.</p><p>If you have ANY questions about the operation of this online shop, please <a href="%s">contact the store owner</a>.</p>';

Done..
:)
User avatar
gabbya
 
Posts: 26
Joined: Sun May 06, 2012 10:39 am

Re: Customer Verification e-mail feature in OpenCart

Postby polewest » Sun Jun 03, 2012 5:35 am

Thanks for that. However the Captcha validation does not work perfeclty as as long you have between 4 and 20 characters it will be accepted. So to correct it make sure you change the following:

Controller: /catalog/controller/account/register.php

REPLACE
if ((utf8_strlen($this->request->post['captcha']) < 4) || (utf8_strlen($this->request->post['captcha']) > 20)) {
$this->error['captcha'] = $this->language->get('error_captcha');
}

WITH

if ((utf8_strlen($this->request->post['captcha']) < 4) || (utf8_strlen($this->request->post['captcha']) > 20
|| ($this->session->data['captcha'] != $this->request->post['captcha']))) {
$this->error['captcha'] = $this->language->get('error_captcha');
}

Polewest
polewest
 
Posts: 18
Joined: Mon May 21, 2012 12:48 am

Re: Customer Verification e-mail feature in OpenCart

Postby forexengineer.us » Sat Jul 21, 2012 12:42 am

Hello, any one test on v5.3.1?
im out of idea because the option for " APPROVE NEW CUSTOMERS" is missing =(
Anyone? ??? ??? ???
forexengineer.us
 
Posts: 32
Joined: Sat Jul 21, 2012 12:40 am

Re: Customer Verification e-mail feature in OpenCart

Postby Finezze » Sat Jul 21, 2012 9:45 am

Hello, on OC 1.5.3.1 it is in:

sales > custumers > customers groups

;)
Finezze
 
Posts: 15
Joined: Sun Jul 15, 2012 10:18 pm

Re: Customer Verification e-mail feature in OpenCart

Postby forexengineer.us » Sat Jul 21, 2012 10:30 am

wah!
somebody care my question! :)

Thanks ya! ;D
forexengineer.us
 
Posts: 32
Joined: Sat Jul 21, 2012 12:40 am

Re: Customer Verification e-mail feature in OpenCart

Postby forexengineer.us » Sat Jul 21, 2012 11:40 am

Hi all, i need help! ???
as i apply this script / method and all is ok,

but why the last method not sending the email? i mean the store return this message :
Your Account Has Been Created!

Thank you for registering with UNISEX || aLL in One pLace!

You will be notified by email once your account has been activated by the store owner.

If you have ANY questions about the operation of this online shop, please contact the store owner.


INSTEAD OF

Thanks blah blah, we have send the email varification and blah.
i check the mail box also the same, no varification link sent.

Why2? help2, any one expert please help me.

Here is my main URL : forexengineer.us
Thanks, :-\
forexengineer.us
 
Posts: 32
Joined: Sat Jul 21, 2012 12:40 am

Re: Customer Verification e-mail feature in OpenCart

Postby forexengineer.us » Sat Jul 21, 2012 12:09 pm

NOw it nearly solve!, but it seem not so better.

you try forexengineer.us and get registered. after some period, the store just pass this in browser without any design or any template that "nice"

Just a plain text and wrote this : Welcome and thank you for registering at UNISEX || aLL in One pLace! text_email_verification http://www.forexengineer.us/index.php?r ... b3a5&u=290 Upon logging in, you will be able to access other services including reviewing past orders, printing invoices and editing your account information. Thanks, UNISEX || aLL in One pLace


so how to make it nice with template like it said successfully when there have no validation before?
forexengineer.us
 
Posts: 32
Joined: Sat Jul 21, 2012 12:40 am

Re: Customer Verification e-mail feature in OpenCart

Postby Finezze » Sun Jul 22, 2012 11:46 am

Hi.. we had a problem here. It works perfectly once the customer clicks in log in... He receives the validation email. He clicks, everything is fine, but if the customer adds a product to the cart and tries to checkout - without registering first - he completes the step one (name, address, etc) and when he clicks to continue the system doesn's take him to step 2.. instead says the register was done successfully ... so the customer has to leave the page, go to the email, click on the validation link and do the the whole shipping again... so they leave the shipping cart :(

tips for any solution?

thanks
Finezze
 
Posts: 15
Joined: Sun Jul 15, 2012 10:18 pm

Re: Customer Verification e-mail feature in OpenCart

Postby twicem » Fri Aug 31, 2012 10:06 am

Hi, thank you very much for tutorial and for the files. But I have the same problem as forexengineer here. Everything works fine, just after filling in the registration form here is white html with text with generated validation link - which is only for confirmation e-mail :( (instead of the success part of site). Any help? Thanks, Mike
twicem
 
Posts: 1
Joined: Fri Aug 31, 2012 9:57 am

Re: Customer Verification e-mail feature in OpenCart

Postby balveer » Tue Oct 16, 2012 3:03 am

hello everyone...

i have a problem.when i am using facebook login after installing email verification module ...facebook user are also required email verification...and my client says their is no need of verification if user login using facebook...can anybody give me thr solution..how to bypass email verification when facebook users login..and other user which register with opencart have to verify...

my opencart version is 1.5.3.1..
and i am using facebookjsconnect extention for facebook login...please reply asap..its argent
balveer
 
Posts: 3
Joined: Tue Oct 16, 2012 2:55 am

Re: Customer Verification e-mail feature in OpenCart

Postby saulius » Tue Mar 26, 2013 8:12 am

catalog/model/account/customer.php has line:
echo $message; die();
I think it would be better use redirect instead of echo there.
saulius
 
Posts: 1
Joined: Tue Mar 26, 2013 8:11 am

Re: Customer Verification e-mail feature in OpenCart

Postby a18327 » Tue Apr 09, 2013 3:56 pm

Excelente
Funciona en la versión 1.5.4.1
Solo que hay que hacer algunos cambios en los textos del archivo success.php de la carpeta language/english/account y hay dos textos ($_['text_account'] y $_['text_verification']) que faltan en el archivo de verification.php de la carpeta language/english/account y quitar el link de login en el correo que se envía, en el archivo customer.php de la carpeta model/account.
a18327
 
Posts: 7
Joined: Thu Jan 31, 2013 3:55 pm

Re: Customer Verification e-mail feature in OpenCart

Postby webmarina » Mon Aug 19, 2013 5:25 am

webmarina
 
Posts: 2
Joined: Sat Aug 10, 2013 10:31 am

Re: Customer Verification e-mail feature in OpenCart

Postby misspiggy » Tue Apr 22, 2014 2:06 am

I use the verification code.
Only thing I'm missing. When clicking on the activation link again you will get an error message.
I want it then to be redirected to the store (with maybe message that the link is already been activated).

Do you know how to do this?

Thanks!
misspiggy
 
Posts: 7
Joined: Fri Nov 18, 2011 6:37 am

Re: Customer Verification e-mail feature in OpenCart

Postby forexengineer.us » Tue Apr 22, 2014 2:47 am

misspiggy wrote:I use the verification code.
Only thing I'm missing. When clicking on the activation link again you will get an error message.
I want it then to be redirected to the store (with maybe message that the link is already been activated).

Do you know how to do this?

Thanks!



You can pm me. I already pmed you ;)
Contact me at top@mynethoster.asia dont waste time to do that :)
forexengineer.us
 
Posts: 32
Joined: Sat Jul 21, 2012 12:40 am

Re: Customer Verification e-mail feature in OpenCart

Postby directory92 » Fri Aug 15, 2014 4:28 pm

How can I put Image in emails, when someone register email should send with an image, and when we manually approve customer email another image is also sent to user. I want to put some graphices in emails,

Any idea how to do this or how to do this with customer.php in language folder ?

Advanced Thanks !
directory92
 
Posts: 2
Joined: Sat May 12, 2012 5:59 am


Return to Modifications

Who is online

Users browsing this forum: No registered users and 13 guests

Hosted by Arvixe Web Hosting