feat: mobile首页
This commit is contained in:
30
app/index/config/lang.php
Normal file
30
app/index/config/lang.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
// +----------------------------------------------------------------------
|
||||
// | 多语言设置
|
||||
// +----------------------------------------------------------------------
|
||||
|
||||
return [
|
||||
// 默认语言
|
||||
'default_lang' => env('DEFAULT_LANG', 'zh-cn'),
|
||||
// 允许的语言列表
|
||||
'allow_lang_list' => ['zh-cn', 'en-us'],
|
||||
// 多语言自动侦测变量名
|
||||
'detect_var' => 'lang',
|
||||
// 是否使用Cookie记录
|
||||
'use_cookie' => true,
|
||||
// 多语言cookie变量
|
||||
'cookie_var' => 'think_lang',
|
||||
// 多语言header变量
|
||||
'header_var' => 'think-lang',
|
||||
// 扩展语言包
|
||||
'extend_list' => [
|
||||
'en-us' => app()->getAppPath() . '/lang/en-us/' . (request()->isMobile() ? 'mobile' : 'pc') . '.php',
|
||||
'zh-cn' => app()->getAppPath() . '/lang/zh-cn/' . (request()->isMobile() ? 'mobile' : 'pc') . '.php',
|
||||
],
|
||||
// Accept-Language转义为对应语言包名称
|
||||
'accept_language' => [
|
||||
'zh-hans-cn' => 'zh-cn',
|
||||
],
|
||||
// 是否支持语言分组
|
||||
'allow_group' => true,
|
||||
];
|
||||
Reference in New Issue
Block a user