Blocks ::: block_enrolcode
Maintained by Picture of Robert SchrenkRobert Schrenk, Picture of Zentrum für LernmanagementZentrum für Lernmanagement
This moodle block allows user enrolment by showing temporary access codes.

EnrolByCode 1.2 (Build: 2020061000)

Moodle 3.5, 3.6, 3.7, 3.8, 3.9
Released: Wednesday, June 10, 2020, 9:05 PM


This moodle plugin allows user enrolment by showing temporary access codes. These access codes are only valid as long as they are shown in a modal dialog, but a longer expiration period can be set optionally.

That way an invitation link to a course can be sent using other media (e-Mail, Messengers, ...) and users can self-enrol directly using that link.

General usage

The plugin adds a button to the participants page of all courses via javascript, that allows teachers to create an access code. The access code can also be shared as a link and a QR code is created dynamically.

Furthermore it injects a button to the main menu using javascript, that allows all users to enter access codes from wherever they are.

When a user enters a valid access code this plugin will check for the first occurrance of a "manual enrol method" of the referenced course. If the first manual enrol method found is inactive, it will activate it. If it finds none, it creates a default one in that course.

The block

The block can be added to any course page, on the frontpage or dashboard. Within a course page it allows the creation of codes, and offers a field to enter access codes to users.

Version information

Version build number
Version release name
1.2 (Build: 2020061000)
Stable version
MD5 Sum
Supported software
Moodle 3.5, Moodle 3.6, Moodle 3.7, Moodle 3.8, Moodle 3.9
  • Latest release for Moodle 3.5
  • Latest release for Moodle 3.6
  • Latest release for Moodle 3.7
  • Latest release for Moodle 3.8
  • Latest release for Moodle 3.9

Version control information

Version control system (VCS)
VCS repository URL
VCS branch

Default installation instructions for plugins of the type Blocks

  1. Make sure you have all the required versions.
  2. Download and unpack the block folder.
  3. Place the folder (eg "myblock") in the "blocks" subdirectory.
  4. Visit http://yoursite.com/admin to complete the installation
  5. Turn editing on in any home or course page.
  6. Add the block to the page
  7. Visit the config link in the block for more options.