Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
integration
prechecker
Commits
f7666835
Commit
f7666835
authored
Sep 23, 2015
by
David Monllaó
Committed by
Andrew Nicols
Sep 23, 2015
Browse files
MDL-50332 enrol_self: Setting form url for guests
Credit to Andrew Nicols.
parent
3bf8439e
Changes
1
Hide whitespace changes
Inline
Side-by-side
enrol/self/lib.php
View file @
f7666835
...
...
@@ -249,7 +249,11 @@ class enrol_self_plugin extends enrol_plugin {
$data
=
new
stdClass
();
$data
->
header
=
$this
->
get_instance_name
(
$instance
);
$data
->
info
=
$enrolstatus
;
$form
=
new
enrol_self_empty_form
(
null
,
$data
);
// The can_self_enrol call returns a button to the login page if the user is a
// guest, setting the login url to the form if that is the case.
$url
=
isguestuser
()
?
get_login_url
()
:
null
;
$form
=
new
enrol_self_empty_form
(
$url
,
$data
);
}
ob_start
();
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment