MDL-52843 users: Fix the PARAM type of the name fields in signup form

If editing the profile, the useredit_shared_definition() function set
the type of all name fields to PARAM_NOTAGS. This patch sets that type
consistently in the user signup form, too.
This commit is contained in:
David Mudrák
2016-01-20 11:03:32 +01:00
parent 6a01418aa1
commit 960c5cce5c
+1 -1
View File
@@ -63,7 +63,7 @@ class login_signup_form extends moodleform {
$namefields = useredit_get_required_name_fields();
foreach ($namefields as $field) {
$mform->addElement('text', $field, get_string($field), 'maxlength="100" size="30"');
$mform->setType($field, PARAM_TEXT);
$mform->setType($field, PARAM_NOTAGS);
$stringid = 'missing' . $field;
if (!get_string_manager()->string_exists($stringid, 'moodle')) {
$stringid = 'required';