moodle-expcontent/mod_form.php

28 lines
869 B
PHP
Raw Normal View History

2021-07-06 14:08:32 +00:00
<?php
if (!defined('MOODLE_INTERNAL')) die();
require_once($CFG->dirroot.'/course/moodleform_mod.php');
require_once($CFG->dirroot.'/mod/expcontent/lib.php');
class mod_expcontent_mod_form extends moodleform_mod {
function definition() {
global $CFG, $DB, $OUTPUT;
$mform =& $this->_form;
$mform->addElement('text', 'name', get_string('name', 'expcontent'), array('size'=>'64'));
$mform->setType('name', PARAM_TEXT);
$mform->addRule('name', null, 'required', null, 'client');
$mform->addElement('text', 'contentid', get_string('contentid', 'expcontent'), array('size'=>'64'));
$mform->setType('contentid', PARAM_TEXT);
$mform->addRule('contentid', null, 'required', null, 'client');
$this->standard_coursemodule_elements();
$this->add_action_buttons();
}
}