3

We have a Joomla system where users can self-activate their accounts. However some users have had problems with this (eg the activation email never arrived) and have had their accounts activated by the site administrators.

But is there any way to tell retrospectively which users were self activated and which were activated manually by admin? (and even better, by which admin user?)

  • By default, this isn't possible, so you'd probably need to create a small plugin if an extension doesn't already exists for something like this. – Lodder Jul 8 '16 at 11:02
  • Okay. Thanks. That's a pity. For now I've asked our support team to put a user note on the account when they do a manual activation, but they seem to have forgotten to do that in couple of instances, and it's caused a bit of confusion so I was hoping for an automatic way of tracking it. I might consider writing a plugin, but for now the manual process of writing a note will suffice. – Simba Jul 8 '16 at 11:08
  • 1
    This may be of great help: joomla.stackexchange.com/questions/14922/… – Lodder Jul 8 '16 at 11:13
  • @Lodder - thank you, yes indeed it was of great help. I have now written my own plugin for this. I've submitted it and I'll post an answer to this question with the URL as soon as it's been approved on the JED. – Simba Jul 14 '16 at 8:44
  • 1
    @Lodder - plugin was finally approved on JED. Edited the answer to include a link. – Simba Aug 19 '16 at 11:35
3

I have been able to resolve this question by writing my own plugin, as recommended by Lodder in the comments.

My plugin is very simple; it merely creates a user note against the user when the user's account is activated.

Activation can occur in three ways:

  • The user activates their account via the activation email.
  • The site admin activates the account manually via the user admin list.
  • The account is activated automatically when created (ie no activation required either because of general Joomla config or because the account was created in the admin panel)

A user note will be created in any of these three circumstances; the text of the note will vary accordingly.

You can find the plugin here on github

The plugin has also been accepted for inclusion in the JED. You can find the entry for it here: http://extensions.joomla.org/extensions/extension/clients-a-communities/user-management/notify-activation.

  • 1
    Thanks a lot for this plugin, didn't know I need it until you made it ;-) Nice... – Mikan Aug 19 '16 at 17:26
1

I did a huge research to see if there is a way to find out. The answer is probably "No", but, you may be able to get some positive results. Here are my findings:

  • From within Joomla, it is not possible to do do that.

  • From within the server, it is somehow possible to do it by examining the Apache access logs, but with great difficulty.

You will need to examine the logs and do a grep for registration.activate, which means that this activation was done by the user. Now, the issue is, you won't be able to find which user it is because the hash value is erased from the database once the user is activated. However, there might be some "signs" that will tell you, if you examine the logs very closely, which user is that (maybe track the IP and check its activities).

Of course, doing this manually is only practical if you have a few users every week. Otherwise, you will need to develop a script for log analysis (look at awk).

Your question is by far one of the most interesting I have ever attempted to answer, and I literally researched it for a couple of hours.

  • 1
    Thanks for the answer. However, I did manage to find a way to solve the problem for myself by writing a small plugin. Please see my answer. (and please feel free to download and use the plugin for yourself if you're interested). – Simba Jul 29 '16 at 13:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.