41 lines
970 B
PHP
41 lines
970 B
PHP
<?php
|
|
// 加载框架引导文件
|
|
define('APP_PATH', __DIR__ . '/../../application/');
|
|
define('MODULE_ROOT', __DIR__ .'/../../');
|
|
// 加载框架引导文件
|
|
require __DIR__ . '/../../thinkphp/base.php';
|
|
function url(){}
|
|
// 关闭路由
|
|
\think\App::route(false);
|
|
|
|
$request = \think\Request::instance();
|
|
|
|
$paramArr = explode('/', $request->pathinfo());
|
|
|
|
$result = [];
|
|
for ($i = 0; $i < count($paramArr); $i += 2) {
|
|
$key = $paramArr[$i];
|
|
$value = isset($paramArr[$i + 1]) ? $paramArr[$i + 1] : null;
|
|
$result[$key] = $value;
|
|
|
|
$request->get([$key=>$value]);
|
|
}
|
|
|
|
|
|
|
|
if(!empty($result) &&isset($result['uniacid'])){
|
|
define('UNIACID',$result['uniacid']);
|
|
}else{
|
|
return false;
|
|
}
|
|
|
|
//这里适配了database配置文件中获取微擎配置
|
|
define('IA_ROOT','../../../..');
|
|
define('MODULE_URL',str_replace("payment/notifyr","",__DIR__));
|
|
define('IN_IA','payment');
|
|
define('W7_ROUTE','api/pay/notifyr');
|
|
|
|
|
|
// 执行应用
|
|
\think\App::run($request)->send();
|
|
?>
|