mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 14:27:22 +01:00
b74ceb3ff5
AMOS BEGIN MOV [importgroups,core],[importgroups,core_group] AMOS END
32 lines
897 B
PHP
32 lines
897 B
PHP
<?php
|
|
|
|
if (!defined('MOODLE_INTERNAL')) {
|
|
die('Direct access to this script is forbidden.'); /// It must be included from a Moodle page
|
|
}
|
|
|
|
require_once($CFG->libdir.'/formslib.php');
|
|
|
|
class groups_import_form extends moodleform {
|
|
|
|
function definition() {
|
|
$mform =& $this->_form;
|
|
$data = $this->_customdata;
|
|
|
|
//fill in the data depending on page params
|
|
//later using set_data
|
|
$mform->addElement('header', 'general');
|
|
|
|
$filepickeroptions = array();
|
|
$filepickeroptions['filetypes'] = '*';
|
|
$filepickeroptions['maxbytes'] = get_max_upload_file_size();
|
|
$mform->addElement('filepicker', 'userfile', get_string('import'), null, $filepickeroptions);
|
|
|
|
$mform->addElement('hidden', 'id');
|
|
|
|
$this->add_action_buttons(true, get_string('importgroups', 'core_group'));
|
|
|
|
$this->set_data($data);
|
|
}
|
|
}
|
|
|