已经在入口文件index.php中动态注册了域名的
// [ 应用入口文件 ]
// 定义应用目录
define('APP_PATH', __DIR__ . '/../application/');
// 定义上传目录
define('UPLOAD_PATH', __DIR__ . '/../public');
// 定义应用缓存目录
define('RUNTIME_PATH', __DIR__ . '/../runtime/');
// 开启调试模式
define('APP_DEBUG', true);
if (! defined("TOP_SDK_WORK_DIR")) {
define("TOP_SDK_WORK_DIR", "/tmp/");
}
// 加载框架引导文件
require __DIR__ . '/../thinkphp/start.php';
\Think\Route::domain('www.mall.com','mall');application中config也允许了// 域名部署
'url_domain_deploy' => true,有知道如何绑定域名的同学感谢你的分享 最佳答案