1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-30 21:40:43 +02:00

[ticket/13740] Login admin when install finished

PHPBB3-13740
This commit is contained in:
Mate Bartus
2015-07-23 20:50:33 +02:00
parent dd31020fb3
commit fbd5929606
7 changed files with 101 additions and 7 deletions

View File

@@ -165,6 +165,19 @@
}
}
// Set cookies
function setCookies(cookies) {
var cookie;
for (var i = 0; i < cookies.length; i++) {
// Set cookie name and value
cookie = encodeURIComponent(cookies[i].name) + '=' + encodeURIComponent(cookies[i].value);
// Set path
cookie += '; path=/';
document.cookie = cookie;
}
}
/**
* Parse messages from the response object
*
@@ -199,6 +212,10 @@
if (responseObject.hasOwnProperty('nav')) {
updateNavbarStatus(responseObject.nav);
}
if (responseObject.hasOwnProperty('cookies')) {
setCookies(responseObject.cookies);
}
}
/**
@@ -321,6 +338,7 @@
$contentWrapper.append($spinner);
}
// Submits a form
function submitForm($form, $submitBtn) {
$form.css('display', 'none');