General developer forum

Prevent multiple users with same ID at the same time

 
Picture of Peshali Randika
Prevent multiple users with same ID at the same time
 

Hi All ,

I am  trying to limit the concurrent users in my moodle site. It removes the oldest user. 

I want to display message telling "Already logged in" or something.

Can I do that ?

If anyone familiar with the code please help.

 
Average of ratings: -
Picture of Visvanath Ratnaweera
Re: Prevent multiple users with same ID at the same time
Particularly helpful Moodlers
Hi

Have a look at the Unique Login plug-in https://moodle.org/plugins/auth_uniquelogin. Never used, could be the one you are looking for.
 
Average of ratings: -
Picture of Jon Bolton
Re: Prevent multiple users with same ID at the same time
Particularly helpful MoodlersTesters

If you go to Site Admin > Plugins > Authentication > Manage Authentication, you can limit the number of concurrent logins for a user.

From the Moodle Docshttps://docs.moodle.org/34/en/Managing_authentication

By default, there is no limit to the number of concurrent browser logins. (If a user is concerned about this, they can view their Browser sessions page.) This setting allows you to specify how many concurrent browser logins are allowed. Once the limit is reached, the oldest session will be terminated. Note that this does not work with Single sign on plugins.

 
Average of ratings: Useful (1)