#2782: _d3GetNonBaseLanguageUrls() liefert falsche URLs wenn die SSL-Verbindung über eine Subdomain läuft
This commit is contained in:
parent
370734c123
commit
0166ff5ff5
@ -123,21 +123,40 @@ class d3_oxcmp_utils_googleanalytics extends d3_oxcmp_utils_googleanalytics_pare
|
|||||||
{
|
{
|
||||||
$myConfig = oxRegistry::getConfig();
|
$myConfig = oxRegistry::getConfig();
|
||||||
$aLanguageUrls = $myConfig->getConfigParam('aLanguageURLs');
|
$aLanguageUrls = $myConfig->getConfigParam('aLanguageURLs');
|
||||||
$aUrls = array();
|
$aSslLanguageUrls = $myConfig->getConfigParam('aLanguageSSLURLs');
|
||||||
/** @var oxUBase $oActView */
|
|
||||||
$oActView = $myConfig->getTopActiveView();
|
|
||||||
|
|
||||||
|
$aUrls = array();
|
||||||
if ($myConfig->getConfigParam('bl_perfLoadLanguages')) {
|
if ($myConfig->getConfigParam('bl_perfLoadLanguages')) {
|
||||||
$aLanguages = oxRegistry::getLang()->getLanguageArray(null, true, true);
|
$aLanguages = oxRegistry::getLang()->getLanguageArray(null, true, true);
|
||||||
reset($aLanguages);
|
reset($aLanguages);
|
||||||
while ((list($sKey, $oVal) = each($aLanguages))) {
|
foreach ($aLanguages as $oVal) {
|
||||||
$aLanguages[$sKey]->link = $oActView->getLink($oVal->id);
|
$aUrls = $this->_d3AddLanguageUrlsToList($aLanguageUrls, $oVal, $aSslLanguageUrls, $aUrls);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return $aUrls;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param $aLanguageUrls
|
||||||
|
* @param $oVal
|
||||||
|
* @param $aSslLanguageUrls
|
||||||
|
* @param $aUrls
|
||||||
|
*
|
||||||
|
* @return array
|
||||||
|
*/
|
||||||
|
protected function _d3AddLanguageUrlsToList($aLanguageUrls, $oVal, $aSslLanguageUrls, $aUrls)
|
||||||
|
{
|
||||||
$sUrl = str_replace('http://', '', $aLanguageUrls[$oVal->id]);
|
$sUrl = str_replace('http://', '', $aLanguageUrls[$oVal->id]);
|
||||||
|
$sSslUrl = str_replace('https://', '', $aSslLanguageUrls[$oVal->id]);
|
||||||
|
|
||||||
if ($aLanguageUrls[$oVal->id] != $aLanguageUrls[oxRegistry::getLang()->getBaseLanguage()]) {
|
if ($aLanguageUrls[$oVal->id] != $aLanguageUrls[oxRegistry::getLang()->getBaseLanguage()]) {
|
||||||
$aUrls[] = "'" . $sUrl . "'";
|
$aUrls[] = "'" . $sUrl . "'";
|
||||||
}
|
}
|
||||||
}
|
if ($aSslLanguageUrls[$oVal->id] != $aSslLanguageUrls[oxRegistry::getLang()->getBaseLanguage()]) {
|
||||||
|
$aUrls[] = "'" . $sSslUrl . "'";
|
||||||
|
|
||||||
|
return $aUrls;
|
||||||
}
|
}
|
||||||
|
|
||||||
return $aUrls;
|
return $aUrls;
|
||||||
|
Loading…
Reference in New Issue
Block a user