mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00
upgrade: MDL-19763 Improve the redirect that forces a DB upgrade when there are major changes
Also fix redirect, so 303 redirects don't need to fully initialise $OUTPUT.
This commit is contained in:
parent
8dff48bf45
commit
5e39d7aa09
5 changed files with 55 additions and 31 deletions
|
@ -4941,6 +4941,8 @@ function redirect($url, $message='', $delay=-1) {
|
|||
//302 might not work for POST requests, 303 is ignored by obsolete clients.
|
||||
@header($_SERVER['SERVER_PROTOCOL'] . ' 303 See Other');
|
||||
@header('Location: '.$url);
|
||||
echo bootstrap_renderer::plain_redirect_message($encodedurl);
|
||||
exit;
|
||||
}
|
||||
|
||||
// Include a redirect message, even with a HTTP redirect, because that is recommended practice.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue