Commit e040ec35 authored by Nigel McNie's avatar Nigel McNie Committed by Nigel McNie
Browse files

Disallow registrations when there are no institutions to register for.

parent 5449ecd1
......@@ -86,6 +86,7 @@ $string['lastname'] = 'Last name';
$string['lastnamedescription'] = 'Your last name';
$string['password2description'] = 'Your password again';
$string['registerdescription'] = 'Welcome! To use this site you must first register. You must also agree to the <a href="terms.php">terms and conditions</a>. The data we collect here will be stored according to our <a href="privacy.php">privacy statement</a>.';
$string['registeringdisallowed'] = 'Sorry, you cannot register for this system at this time';
// Forgot password
$string['cantchangepassword'] = 'Sorry, you are unable to change your password through this interface - please use your institution\'s interface instead';
......
......@@ -224,12 +224,15 @@ if (count($institutions) > 1) {
'options' => $options
);
}
else {
else if ($institutions) {
$elements['institution'] = array(
'type' => 'hidden',
'value' => 'mahara'
);
}
else {
die_info(get_string('registeringdisallowed'));
}
$elements['tandc'] = array(
'type' => 'radio',
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment