Note: You are currently viewing documentation for Moodle 2.4. Up-to-date documentation for the latest stable version of Moodle may be available here: Flat file.

Flat file: Difference between revisions

From MoodleDocs
No edit summary
m (added link to spanish translation of document)
 
(18 intermediate revisions by 9 users not shown)
Line 1: Line 1:
Location: ''Administration > Courses > Enrolments''
{{Enrolment}}
Location: Flat file edit settings link in ''Site administration > Plugins > Enrolments > Manage enrol plugins''




Like the upload users tool, this method checks for an enrolment file at the specified location. You can put the file anywhere you want (as long as Moodle can find it), but if you don't specify a location, Moodle will look for the file at ''.../moodledata/1/enrolments.txt''. If you do specify a file path, it should be absolute (eg /var/moodledata/enrolments.txt) and can be read and modified by the webserver process.
A flat file allows bulk enrolment management (enrol or unenrol) of existing users in existing course. The file is read one time by Moodle then erased. The file is located in the moodle file structure as a text file and [[Cron]] provides the timing when it is read.
If Moodle finds a new file, it will process the data and delete the file afterwards. You can choose to have a log file send to the administrator and to send a notification to teachers and students.


The file should be structured with the action, role, student number (see student profile) and course ID number (see course settings).
==Options==
The site administrator should edit the settings for a flat file if it is enabled.  


The flat file settings page includes information on flat file formatting.
[[Image:EnrolSettngsFlatFile 2.0.png]]
   
 
You should specify an absolute path for the upload file (eg /var/moodledata/enrolments.txt) where it can be read and modified by the webserver process.
 
You can choose to have an email sent to notify the Administrator, Teachers and/or students when the file has been processed.
 
==Flat file structure==
The file should be structured with the action, role, user id, and course ID number. Optionally a start time and end time can be added as additional fields.


==See also==
==See also==
*[[Upload users]]
*[[Upload users]]
*Using Moodle [http://moodle.org/mod/forum/discuss.php?d=13289 How does flat file work?] forum discussion
*[[Bulk user actions]] how to download site user information (including userIDs)
 
Using Moodle forum discussions:
[[Category:Enrolment]]
*[http://moodle.org/mod/forum/discuss.php?d=144997 Flat file enrolments - how is this typically used by organisations?]


[[fr:Inscription par fichier plat]]
[[fr:Inscription par fichier plat]]
[[de:Einschreibung über CSV-Datei]]
[[es:Archivo plano]]

Latest revision as of 19:04, 8 March 2014

Location: Flat file edit settings link in Site administration > Plugins > Enrolments > Manage enrol plugins


A flat file allows bulk enrolment management (enrol or unenrol) of existing users in existing course. The file is read one time by Moodle then erased. The file is located in the moodle file structure as a text file and Cron provides the timing when it is read.

Options

The site administrator should edit the settings for a flat file if it is enabled.

EnrolSettngsFlatFile 2.0.png

You should specify an absolute path for the upload file (eg /var/moodledata/enrolments.txt) where it can be read and modified by the webserver process.

You can choose to have an email sent to notify the Administrator, Teachers and/or students when the file has been processed.

Flat file structure

The file should be structured with the action, role, user id, and course ID number. Optionally a start time and end time can be added as additional fields.

See also

Using Moodle forum discussions: