Admin tools: Upload enrolment methods

Maintained by Picture of Eoin Campbell Eoin Campbell
This plugin allows administrators add the "Course meta link" and "Cohort sync" enrolment methods to a range of courses from a CSV file. They can also delete, enable or disable existing enrolment methods in a course.
39 sites
5 fans

This plugin is an enhanced version of the Upload Metacourse links block plugin on which it is based. It also provides a good work-around for a longstanding issue with the Course upload facility whereby enrolment methods are not fully supported.

Use the command Site administration > Plugins > Enrolments > Upload enrolment methods to upload a CSV file containing lines of the form:

operation, enrolment method, target course shortname, parent course shortname or cohort idnumber, disabled, group



Lines beginning with a '#' or ';' character are comments, and skipped.
Each line of the file contains one record.
Each record is a series of data in a fixed order separated by commas.
All fields are required.
The allowed operations are add, del(ete), and upd(ate).
The allowed methods are 'meta' and 'cohort'.
The allowed disabled status values are 1 (enable) and 0 (disable).
The group field is the name of a group into which enrolled students should be placed. It will be created if it doesn't already exist (this field is not yet supported).

This plugin enhances the original in that it is possible to disable existing enrolment methods in batch mode, and also that it can add an enrolment method to a course but leave it disabled.


Screenshot #0


Picture of Eoin Campbell
Eoin Campbell (Lead maintainer)
Please login to view contributors details and/or to contact them

Comments RSS

Show comments
  • Picture of Plugins bot
    Tue, 17 Apr 2018, 12:00 AM
    Approval issue created: CONTRIB-7263
  • Picture of Roland Sherwood
    Thu, 12 Jul 2018, 10:01 AM
    Just what we've been looking for - many thanks!
  • Wazza
    Fri, 20 Jul 2018, 8:51 PM
    I have been asking for this many, many years. And if Moodle wants to be a LMS that operates in a landscape of other educational tools, they'd better fix there webservice to do this to (add cohorts to a course). Thanks!
  • Wazza
    Tue, 23 Oct 2018, 9:11 PM
    Improvement suggestion: I think the US uses comma delimited files (csv) where Europe uses ; to mark the difference in fields. Where csv upload in Moodle is possible, you can usually select which delimiter to use. In this plugin I can not choose so I always end up saving the file from Excel, opening it in a text editor en search replace ; for ,
  • Picture of Eoin Campbell
    Thu, 25 Oct 2018, 4:13 AM
    This is a nice idea, Moodle has a CSV library to allow this, and also make CSV files position independent by using a heading row. Might get to it sometime.
Please login to post comments