Skip to the content
Documentation

User registration with approval

No ratings yet

On some sites a new account should not work until someone has looked at it: a new editor's account, or the registration of a member on an intranet or a club site. Exponential does this with the same approval that holds content: a workflow event keeps the new account unpublished, the approvers decide in the administration, and only an approved account can sign in.

How it works

  1. Someone creates an account in a group that needs approval: a visitor who registers, or an editor who creates a colleague's account.
  2. The workflow event Approve user accounts holds the account. It is not published and cannot sign in; it shows as waiting for approval.
  3. The approvers get an e-mail, New user account waiting for approval, with a link to the approval in the administration. The link approves nothing by itself.
  4. An approver opens the approval (from the mail, or Dashboard > Collaboration), may add a comment, and presses Approve or Deny. Verify it's you may ask for the approver's password first.
  5. Approve publishes the account at once: it can sign in. Deny leaves it unpublished. The first decision counts for all approvers.

Requests, approvals, denials and refused attempts are recorded in the User audit log.

New editor accounts

A new installation already approves new editor accounts: editors may create the account of a new colleague in Editors, and an administrator approves it. An administrator's own new accounts are published directly. The editor sees the waiting account under My pending items; after a denial it is back in the editor's drafts.

What lets editors do this is the role Editor account requests, assigned to Editors: it allows opening the Editors group and creating a user account directly in it, and nothing else there.

The page of the role Editor account requests with its two policies

The role Editor account requests, given to Editors on a new installation: editors may open the Editors group and create a user account directly in it, which then waits for approval.

Members who register themselves

To make the registrations of visitors wait as well, extend the same event:

  1. Open Setup > Workflows and the workflow that holds the event Approve user accounts (on a new installation Approve new editor accounts), and edit it.
  2. Add Members to User groups whose new accounts need approval.
  3. Under Groups who approve the accounts (or Users who approve the accounts), add who decides, for example a group of moderators.
  4. Leave Send the approvers an e-mail on, and save.
The workflow groups of the administration

Setup, Workflows: the workflows in their groups, the triggers that run them, and the processes waiting. An approval of new accounts is a workflow event set up here.

The workflow runs on the trigger content / publish / before. Where the workflow is missing on an older installation, the administrator of the server adds it with php bin/php/adduserapproval.php --apply.

Registrations whose owners never confirmed their e-mail address are listed under Users > Unactivated users; see User registration.

Another way: by section

Instead of the event above, the kernel's plain Approve event can hold new accounts by section: give the accounts that need approval a section of their own and an approval event for that section. Choose one of the two ways, never both, or each account is asked for twice.

What can go wrong

  • The approvers get no e-mail. Their accounts need a real e-mail address, the site must be able to send e-mail, and Send the approvers an e-mail must be on. The approval is also listed under Dashboard > Collaboration.
  • The link in the mail opens the wrong address. The administration's address for these links is set in site.ini [UserSettings] RegistrationAdminBaseURL.
  • Moving a member into Editors is refused. That would skip the approval; create a new account in Editors instead.
  • The event refuses to be saved. It needs at least one group that needs approval, and at least one approving user or group.

Read more

Contributors

Comments

Add a comment

Comments are read by a moderator before they appear.