News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Distinguish activations (account/email)

Started by HunterP, May 22, 2011, 06:31:40 AM

Previous topic - Next topic

HunterP


Hi there,

Maybe an odd subject, but didn't know how to summarize my question...

The function adminNotify() in Subs-Post.php notifies the admin(s) of new registrations, but also the activation of a changed email address.
Is there any way of distinguishing those type of notifications in adminNotify() , or in the calling functions, possibly by adding a flag or someting?

Chas Large

The e-mail change verification e-mail is the same as a new user verification so no way to change that.

When an e-mail is verified either upon joining or upon changing their e-mail, the same call is made and the same e-mail is sent out. The only different e-mail is the New Member e-mail which is slightly different.

You can edit the text to more easily differentiate between Joining and Verifying e-mails in Themes > default > languages > EmailTemplates.language.php
My Modifications :)  My Forum

Please DO NOT PM me with support requests. Post the problem in the appropriate Support Board so everyone can benefit from the advice given.

HunterP


Chas, thanks.

I don't want to edit the email, I want to do some additional coding in this function and need to know how these two actions (account activation and email activation) are separated?

Chas Large

Well I regret I can't answer that specifically but as they are one and the same function it would be difficult. Maybe a new function to call one or the other is required. I'll let someone else pick that up if they can.
My Modifications :)  My Forum

Please DO NOT PM me with support requests. Post the problem in the appropriate Support Board so everyone can benefit from the advice given.

HunterP


Think I've fixed it. In AdminNotify() I added a query which does a COUNT(*) in smf_log_actions for this id_member.
If any logged actions, it has to be an existing member changing emailaddress :)

Advertisement: