mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-27 21:58:52 +00:00
Merge pull request #3075 from Senky/ticket/11613
[ticket/11613] Cookies do not work for netbios domain
This commit is contained in:
commit
6ac088ea2f
1 changed files with 1 additions and 1 deletions
|
@ -1063,7 +1063,7 @@ class session
|
||||||
|
|
||||||
$name_data = rawurlencode($config['cookie_name'] . '_' . $name) . '=' . rawurlencode($cookiedata);
|
$name_data = rawurlencode($config['cookie_name'] . '_' . $name) . '=' . rawurlencode($cookiedata);
|
||||||
$expire = gmdate('D, d-M-Y H:i:s \\G\\M\\T', $cookietime);
|
$expire = gmdate('D, d-M-Y H:i:s \\G\\M\\T', $cookietime);
|
||||||
$domain = (!$config['cookie_domain'] || $config['cookie_domain'] == 'localhost' || $config['cookie_domain'] == '127.0.0.1') ? '' : '; domain=' . $config['cookie_domain'];
|
$domain = (!$config['cookie_domain'] || $config['cookie_domain'] == '127.0.0.1' || strpos($config['cookie_domain'], '.') === false) ? '' : '; domain=' . $config['cookie_domain'];
|
||||||
|
|
||||||
header('Set-Cookie: ' . $name_data . (($cookietime) ? '; expires=' . $expire : '') . '; path=' . $config['cookie_path'] . $domain . ((!$config['cookie_secure']) ? '' : '; secure') . ';' . (($httponly) ? ' HttpOnly' : ''), false);
|
header('Set-Cookie: ' . $name_data . (($cookietime) ? '; expires=' . $expire : '') . '; path=' . $config['cookie_path'] . $domain . ((!$config['cookie_secure']) ? '' : '; secure') . ';' . (($httponly) ? ' HttpOnly' : ''), false);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue