XF 1.5 'Users Awaiting Approval' sort by date instead of alphabetical?

domski2bc

Member
Some users don't receive emails. Is there a way sort the list of 'users awaiting approval' by date instead of alphabetical? I have over 3000 in this state by know and I am only interested in the most recent. I want to start confirming accounts, but only recent ones.
 
library/XenForo/ControllerAdmin/User.php

Add the red code:

Rich (BB code):
	public function actionModerated()
	{
		$users = $this->_getUserModel()->getUsers(array(
			'user_state' => 'moderated'
		), array('limit' => 30, 'order' => 'register_date', 'direction' => 'desc'));

		$class = XenForo_Application::resolveDynamicClass('XenForo_Session');
		/** @var $publicSession XenForo_Session */
		$publicSession = new $class();
		$publicSession->start();

That should do it.
 
@domski2bc be careful, if you upgrade xenforo you will need to re-do the modification.
to make it upgrade proof you need an addon.
True thanks.

Another question.

Is there anyway to batch confirm all accounts that are awaiting an email-confirmation? Currently I have a 'new members' addon and just go one by one manually confirming. I still want to keep email confirmation on as most of my users have no issue.
 
True thanks.

Another question.

Is there anyway to batch confirm all accounts that are awaiting an email-confirmation? Currently I have a 'new members' addon and just go one by one manually confirming. I still want to keep email confirmation on as most of my users have no issue.

Run this query on your database to activate all users who are currently awaiting email confirmation:

Code:
UPDATE xf_user
SET user_state = 'valid'
WHERE user_state = 'email_confirm';
 
to make it upgrade proof you need an addon.
Good point. @AndyB's New Members add-on sorts the new users by date and it's easy to see when some are still in a non-valid state...

Screen Shot 2016-08-05 at 10.10.54 PM.webp

The last four columns are: Msg. Count/Conv. Count/User State/Is-Banned.

Just a heads-up, I find about 10-15% of my un-confirmed users have entered their email address incorrectly during registration.(i.e. bob@gmial.com, etc.) I manually fix those and then resend another confirmation out (via @Apantic's Resend Activation Email add-on), which results in about 90% of those folks finishing up their registration. (y)
 
Top Bottom