Route::group(['domain' => 'gl.com'], function () {
Route::controller('/','HomeController');
});
Route::group(['domain' => 'admin.gl.com'], function () {
Route::get('/', function () {
echo 2;
});
});
这样配置是好的
Route::group(['domain' => 'gl.com'], function () {
Route::controller('/','HomeController');
});
Route::group(['domain' => 'admin.gl.com'], function () {
Route::controller('/','SomeController');
});
如果这样配置就会导致主域名和定义的域名默认使用最后定义的