***** $Id: README.txt,v 1.10 2008/07/28 11:40:16 alanbarrett Exp $ ***** ***** ***** README.txt Alan Barrett alanabarrett0@gmail.com ***** ***** ***** ***** On a PC use Wordpad and NOT Notepad to read this file (saved with UNIX line endings but in ANSI, not UTF-8) ***** ***** ***** Patch for Moodle 2.0 + to allow a per course limit on the number of students ***** ***** ***** Following is not true yet as it we are moving from Moodle 1.9 to 2.0!!!... ***** This patch was downloaded from http://download.moodle.org/download.php/patches/max_enrolment.zip ***** ***** ***** ***** Based on: http://moodle.org/mod/forum/discuss.php?d=50063 ***** ***** ***** ***** Specifically this patch is merged from and will work as part of the MOODLE_19_STABLE code that is ***** ***** due to be built as the MOODLE_19_WEEKLY build each Wednesday (first was 16th April 2008). ***** ***** It will be maintained to work with subsequent MOODLE_19_WEEKLY builds. ***** ***** ***** ***** I have previous versions that will work with earlier builds, contact me if you need one. ***** Install Instructions (after downloading or installing the latest Moodle 2.0 weekly build)... 1) max_enrolment.zip contains one folder called max_enrolment with the following files: README.txt lib/db/install.xml lib/db/upgrade.php admin/index.php admin/roles/assign.php course/edit_form.php course/lib.php course/enrol.php lang/en_utf8/moodle.php lang/en_utf8/help/index.html lang/en_utf8/help/enrolmax.html Copy all the folders (lib, admin, course, lang) over the corresponding folders in the moodle installation. This will replace the existing files except for enrolmax.html which is new. (Or alternatively FTP the files to the appropriate folders in your site one by one.) 2a) If the Moodle site has not yet been installed, just follow the normal installation process. 2b) If the Moodle site has already been installed, go to the URL http://your-site/admin/ and follow any instructions to upgrade the database. If the database version is older than than the latest 2.0 you will see detailed instructions. If the database version is equal to the latest 2.0 the database modification required for this patch will be silent. Settings to enforce a limit on the number enrolled in a specific course... 1) As an administrator, select Courses. 2) Select Add/edit courses. 3) Select a specific course from a specific course category. 4) Select Settings. 5) Two data entry groups below enrolments there is a group called "Enrolment - Limit total number of students for course" with a setting of "Maximum enrolled students" and a help button. 6) Look at the help. 7) Setting a non-zero number for "Maximum enrolled students" will enforce a limit on the maximum number allowed to enrol for this course. 8) It will also cause to be displayed the number of places left for this course in various UI locations. For your information, here are the Database changes made by the patch... 1) In the course table an unsigned integer field called enrolmax is added which is the enrolment limit. 2) A configuration variable enrolmaxenabled is set to indicate the patch is properly installed (set_config('enrolmaxenabled', '1');) Some translations (thanks to Manfred Burkardt)... To use the Spanish version just paste the following text at the end of lang/es_utf8/moodle.php: $string['availableenrolments'] = 'Plazas disponibles'; // ALAN $string['availableenrolmentsnone'] = 'No quedan plazas'; // ALAN $string['availableenrolmentsunlimited'] = 'Illimitadas'; // ALAN $string['enrolcoursefull'] = 'Perdón, el número de inscripciones en este curso ha llegado a su limite. El curso esta lleno.'; // ALAN $string['enrolmax'] = 'Máximo alumnos inscritos'; // ALAN $string['enrolmaxerror'] = 'Máximo alumnos inscritos tiene que ser un numer no negativo sin espacios'; // ALAN $string['enrolmaxheader'] = 'Inscripciones - Limite número de alumnos'; // ALAN $string['enrolmaxshort'] = 'Máximo alumnos'; // ALAN To use the Catalan version just paste the following text at the end of lang/ca_utf8/moodle.php: $string['availableenrolments'] = 'Plaçes disponibles'; // ALAN $string['availableenrolmentsnone'] = 'No queden places'; // ALAN $string['availableenrolmentsunlimited'] = 'Illimitades'; // ALAN $string['enrolcoursefull'] = 'Disculpeu, el nombre d\'inscripcions en aquest curs ha arribat al seu limit. El curs està ple.'; // ALAN $string['enrolmax'] = 'Màxim alumnes inscrits'; // ALAN $string['enrolmaxerror'] = 'Màxim alumnes inscrits ha de ser un nombre no negatiu sense espais'; // ALAN $string['enrolmaxheader'] = 'Inscripcions - Limit nombre d\'alumnes'; // ALAN $string['enrolmaxshort'] = 'Màxim alumnes'; // ALAN Note: Both this README.txt file and moodle.php are encoded in UTF-8. Alan.