Skip to content
Snippets Groups Projects
Commit f9f7c7bc authored by Dries Buytaert's avatar Dries Buytaert
Browse files

- Patch #262920 by ainigma32: language selection for domain should look at...

- Patch #262920 by ainigma32: language selection for domain should look at HTTP_HOST not SERVER_NAME.
parent 45f34467
Branches
Tags
2 merge requests!7452Issue #1797438. HTML5 validation is preventing form submit and not fully...,!789Issue #3210310: Adjust Database API to remove deprecated Drupal 9 code in Drupal 10
......@@ -25,7 +25,7 @@ function language_initialize() {
case LANGUAGE_NEGOTIATION_DOMAIN:
foreach ($languages as $language) {
$parts = parse_url($language->domain);
if (!empty($parts['host']) && ($_SERVER['SERVER_NAME'] == $parts['host'])) {
if (!empty($parts['host']) && ($_SERVER['HTTP_HOST'] == $parts['host'])) {
return $language;
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment