易物php,includes/baijiacms/runner.inc.php · Dragon/易物 - Gitee.com

// +----------------------------------------------------------------------

// |

// +----------------------------------------------------------------------

// | Copyright (c) 2015 http://www.baijiacms.com All rights reserved.

// +----------------------------------------------------------------------

// | Author: 百家cms <1987884799> 1987884799>

// +----------------------------------------------------------------------

defined('SYSTEM_IN') or exit('Access Denied');

if(!empty($_CMS['beid'])&&SYSTEM_ACT=='mobile'&&($modulename=="shopwap"||$_CMS['isaddons']==true||$_GP['m']=='eshop'))

{

$t_set_shop=globalSetting('shop');

if(!empty($t_set_shop['close'])&&!empty($t_set_shop['closedetail']))

{

if(!empty($t_set_shop['closeurl']))

{

message($t_set_shop['closedetail'],$t_set_shop['closeurl'],'error');

}else

{

message($t_set_shop['closedetail']);

}

}

}

$classname = $modulename."Addons";

if($_CMS['isaddons']==true)

{

require(WEB_ROOT.'/system/common/addons.php');

if(SYSTEM_ACT=='mobile')

{

require(WEB_ROOT.'/system/common/mobile.php');

$file = ADDONS_ROOT . $modulename."/mobile.php";

}else

{

$file = ADDONS_ROOT . $modulename."/web.php";

}

}else

{

if(SYSTEM_ACT=='mobile')

{

require(WEB_ROOT.'/system/common/mobile.php');

$file = SYSTEM_ROOT . $modulename."/mobile.php";

}else

{

require(WEB_ROOT.'/system/common/web.php');

$file = SYSTEM_ROOT . $modulename."/web.php";

}

}

if(!is_file($file)) {

exit('ModuleSite Definition File Not Found '.$file);

}

if(!empty($_GP['m']))

{

require(WEB_ROOT.'/system/common/common.php');

}

require $file;

if(!class_exists($classname)) {

exit('ModuleSite Definition Class Not Found');

}

$class = new $classname();

$class->module = $modulename;

$class->inMobile = SYSTEM_ACT=='mobile';

if($_GP['m']!='eshop')

{

if($_CMS['isaddons']==true)

{

if($class instanceof BjModule) {

if(!empty($class)) {

if(isset($_GP['do'])) {

if(SYSTEM_ACT=='mobile')

{

$class->inMobile = true;

}else

{

$_W['isfounder']=true;

if($modulename=='manager')

{

check_managerlogin();

}else

{

check_login();

}

$class->inMobile = false;

}

$method = 'do_'.$_GP['do'];

}

$class->module = $modulename;

if (method_exists($class, $method)) {

exit($class->$method());

}else

{

exit($method." no this method");

}

}

}

exit('BjSystemModule Class Definition Error');

}else

{

if($class instanceof BjSystemModule) {

if(!empty($class)) {

if(isset($_GP['do'])) {

if(SYSTEM_ACT=='mobile')

{

$class->inMobile = true;

}else

{

$_W['isfounder']=true;

if($modulename=='manager')

{

check_managerlogin();

}else

{

check_login();

}

$class->inMobile = false;

}

$method = 'do_'.$_GP['do'];

}

$class->module = $modulename;

if (method_exists($class, $method)) {

exit($class->$method());

}else

{

exit($method." no this method");

}

}

}

}

}else

{

if($class instanceof BJexModule) {

$class->uniacid = $class->weid = $_W['uniacid'];

$class->modulename = $_W['module'];

$class->__define = $file;

$class->inMobile = defined('IN_MOBILE');

if(SYSTEM_ACT=='mobile')

{

define('IN_MOBILE', true);

$method = 'doMobile' . ucfirst($_GPC['do']);

if (method_exists($class, $method)) {

exit($class->$method());

}

exit();

}else

{

define('IN_SYS', true);

define('IN_MODULE', $_W['module']);

define('IN_IA', true);

$_W['isfounder']=true;

$method = 'doWeb' . ucfirst($_GPC['do']);

if (method_exists($class, $method)) {

check_login();

exit($class->$method());

}

exit("访问的方法 {$method} 不存在.");

}

}

exit('BjSystemModule Class Definition Error');

}

一键复制

编辑

Web IDE

原始数据

按行查看

历史

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值