Blogger Information
Blog 3
fans 0
comment 0
visits 1415
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
thinkphp 多应用配置
喂、带朕回家
Original
410 people have browsed it
1、项目创建
composer create-project topthink/think www
2、安装多应用扩展
composer require topthink/think-multi-app
3、根据开发手册调整目录结构
  • 删除app目录下的controller文件夹

  • 生成新的应用模块

  • 开启多应用配置(config/app.php)

  • 应用映射(config/app.php)

  • 域名绑定(config/app.php)

生成新应用模块php think build demo开启多应用配置'auto_multi_app'   => true,应用映射'app_map' => [    'think'  =>  'admin',  // 把admin应用映射为think],域名绑定'domain_bind' => [    'blog'        =>  'blog',  //  blog子域名绑定到blog应用    'shop.tp.com' =>  'shop',  //  完整域名绑定    '*'           =>  'home', // 二级泛域名绑定到home应用],
Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!
All comments Speak rationally on civilized internet, please comply with News Comment Service Agreement
0 comments
Author's latest blog post