1.在simplewind\cmf\common.php 里找到“获取当前主题名”添加
if(cmf_is_mobile()){
$theme = config('cmf_mobile_default_theme');
}else{
$theme = config('cmf_default_theme');
}
![](https://img2018.cnblogs.com/blog/1251386/201909/1251386-20190919101915896-2062019941.png)
![](https://img2018.cnblogs.com/blog/1251386/201909/1251386-20190919101921366-581147189.png)
2. app\config.php 里添加
'cmf_mobile_theme_path' => 'public/themes/', //(public视情况而定加)
'cmf_mobile_default_theme' => 'mobile', //(mobile为手机版文件名)
![](https://img2018.cnblogs.com/blog/1251386/201909/1251386-20190919101935082-1693972109.png)
![](https://img2018.cnblogs.com/blog/1251386/201909/1251386-20190919101939281-1826659739.png)
-------------------------------------------------自己项目--------------------------------------------------------------------------------
![](https://img2018.cnblogs.com/blog/1251386/201909/1251386-20190919102008597-1899061730.png)
![](https://img2018.cnblogs.com/blog/1251386/201909/1251386-20190919102120900-508172596.png)
![](https://img2018.cnblogs.com/blog/1251386/201909/1251386-20190919102229912-1288528152.png)
![](https://img2018.cnblogs.com/blog/1251386/201909/1251386-20190919102229912-1288528152.png)
![](https://img2018.cnblogs.com/blog/1251386/201909/1251386-20190919102249889-589195038.png)
--------------------------------------模板开发之列表分页-------------------------------------------------
![](https://img2018.cnblogs.com/blog/1251386/201909/1251386-20190926092224421-615132610.png)
![](https://img2018.cnblogs.com/blog/1251386/201909/1251386-20190926092231782-1643662768.png)