diff --git a/app/common.php b/app/common.php index 99322f6..7bd1a86 100644 --- a/app/common.php +++ b/app/common.php @@ -299,6 +299,10 @@ function getMuiLangUrl($url) $firstPath = ''; } if(!empty($firstPath)){ + // 首页:/en 而非 /en/(与语言切换 buildLangUrl 一致) + if ($url === '/' || $url === '') { + return '/' . $firstPath; + } $url = '/' . $firstPath . $url; } return $url;