summaryrefslogtreecommitdiff
path: root/includes/bootstrap.inc
diff options
context:
space:
mode:
Diffstat (limited to 'includes/bootstrap.inc')
-rw-r--r--includes/bootstrap.inc5
1 files changed, 3 insertions, 2 deletions
diff --git a/includes/bootstrap.inc b/includes/bootstrap.inc
index 6683371cd..1154b84ae 100644
--- a/includes/bootstrap.inc
+++ b/includes/bootstrap.inc
@@ -299,8 +299,9 @@ function conf_init() {
$session_name = $cookie_domain;
}
else {
- // Otherwise use $base_url for session name.
- $session_name = $base_url;
+ // Otherwise use $base_url as session name, without the protocol
+ // to use the same session identifiers across http and https.
+ list( , $session_name) = explode('://', $base_url, 2);
// We try to set the cookie domain to the hostname.
if (!empty($_SERVER['HTTP_HOST'])) {
$cookie_domain = $_SERVER['HTTP_HOST'];