mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-07 23:22:48 +08:00
route类改进
This commit is contained in:
@@ -228,7 +228,10 @@ class App
|
|||||||
|
|
||||||
// 检测域名部署
|
// 检测域名部署
|
||||||
if (!IS_CLI && !empty($config['domain_deploy'])) {
|
if (!IS_CLI && !empty($config['domain_deploy'])) {
|
||||||
Route::checkDomain($config['domain_rules']);
|
$module = Route::checkDomain($config['domain_rules']);
|
||||||
|
if (null != $module) {
|
||||||
|
define('BIND_MODULE', $module);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 监听path_info
|
// 监听path_info
|
||||||
|
|||||||
@@ -194,7 +194,7 @@ class Route
|
|||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
if (is_array($rule)) {
|
if (is_array($rule)) {
|
||||||
define('BIND_MODULE', $rule[0]);
|
$module = $rule[0];
|
||||||
if (isset($rule[1])) {
|
if (isset($rule[1])) {
|
||||||
// 传入参数
|
// 传入参数
|
||||||
parse_str($rule[1], $parms);
|
parse_str($rule[1], $parms);
|
||||||
@@ -208,10 +208,11 @@ class Route
|
|||||||
$_GET = array_merge($_GET, $parms);
|
$_GET = array_merge($_GET, $parms);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
define('BIND_MODULE', $rule);
|
$module = $rule;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
return isset($module) ? $module : null;
|
||||||
}
|
}
|
||||||
|
|
||||||
// 检测URL路由
|
// 检测URL路由
|
||||||
|
|||||||
Reference in New Issue
Block a user