From 3fe61451686f47dd4895479139d59f7b77324a66 Mon Sep 17 00:00:00 2001 From: Mathieu Lutfy Date: Thu, 7 Nov 2013 14:00:47 -0500 Subject: [PATCH] CRM-13354: fix bad patch for locale detection in Drupal based on domain/suffix --- CRM/Utils/System/Drupal.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CRM/Utils/System/Drupal.php b/CRM/Utils/System/Drupal.php index 692dbe48f8..1e6cd0b3d4 100644 --- a/CRM/Utils/System/Drupal.php +++ b/CRM/Utils/System/Drupal.php @@ -958,7 +958,7 @@ AND u.status = 1 if ($urlType == LOCALE_LANGUAGE_NEGOTIATION_URL_PREFIX) { if (isset($language->prefix) && $language->prefix) { if ($addLanguagePart) { - $url = (CRM_Utils_System::isSSL() ? 'https' : 'http') . '://' . $language->domain . base_path(); + $url .= $language->prefix . '/'; } if ($removeLanguagePart) { $url = str_replace("/{$language->prefix}/", '/', $url); @@ -969,7 +969,7 @@ AND u.status = 1 if ($urlType == LOCALE_LANGUAGE_NEGOTIATION_URL_DOMAIN) { if (isset($language->domain) && $language->domain) { if ($addLanguagePart) { - $url = CRM_Utils_File::addTrailingSlash($language->domain, '/'); + $url = (CRM_Utils_System::isSSL() ? 'https' : 'http') . '://' . $language->domain . base_path(); } if ($removeLanguagePart && defined('CIVICRM_UF_BASEURL')) { $url = str_replace('\\', '/', $url); -- 2.25.1