我安装了最新的Fecro,设置了www.xxx.com 英语, fr.xxx.com法语,es.xxx.com西班牙语 但是通过顶部的语言选择,不能跳转到其他店铺
您只安装了fecro吧? 标题应该写的更确切一点,这个应该是pc入口
代码位置:./addons/fecmall/fecro/app/appfront/theme/fecro/widgets/header.php
./addons/fecmall/fecro/app/appfront/theme/fecro/widgets/header.php
338行左右
function getCaption(url,parameter) { var index = url.lastIndexOf(parameter); if (index >0 ) { url = url.substring(0, index); } return url; } $(".lang_currency").click(function(){ changeStore = $(".modal-language-select-outer-js .currentLang").attr("rel"); currentCurrency = $(".modal-language-select-outer-js .currentCurrency").attr("rel"); ctUrl = "<?= Yii::$service->url->getUrl('cms/home/changecurrency') ?>"; htmlobj=$.ajax({url: ctUrl+"?currency="+currentCurrency, async:false}); location.reload() ; currentUrl = window.location.href; currentStore = $(".current_lang").val(); redirectUrl = currentUrl.replace("://"+currentStore,"://"+changeStore); redirectUrl = getCaption(redirectUrl, "#"); window.location.href=redirectUrl; //alert(redirectUrl); });
您debug一下看看原因。
选择不同语是可以跳到主页,但是在选定后的相对应的语言里要点产品就找不到页面
nginx配置有问题
https://www.fecmall.com/topic/2101
各个语言子项需要加入
location /fr/ { index index.php; if (!-e $request_filename){ rewrite . /fr/index.php last; } }