修改ecshop2.7.0后台路径
2009-09-29 11:08 来源:www.chinab4c.com 作者:ecshop专家
ecshop已经发展到2.7了。ecshop2.7不象其他版本,文件路径和文件调用机智都发生了变化,为了更好的处理ecshop后台路径,增加站的安全性.下面将总结,如何修改ecshop后台路径.
quotation.php
include_once(ROOT_PATH . 'user/includes/lib_main.php');
includes/lib_main.php
include_once(ROOT_PATH . 'user/includes/lib_template.php');
includes/lib_common.php
get_brands(){
include_once(ROOT_PATH . 'user/includes/lib_template.php');
}
data/config
$admin_dir = "user";
admin/picture_batch.php
include_once(ROOT_PATH . '/user/includes/lib_goods.php');
admin/index.php
require_once(ROOT_PATH . 'user/includes/lib_goods.php');
admin/goods.php
require_once(ROOT_PATH . '/user/includes/lib_goods.php');
admin/filecheck.php
checkfiles('user/', '\.php|\.htm|\.js|\.css|\xml');
admin/database.php
require_once(ROOT_PATH . 'user/includes/cls_sql_dump.php');
admin/check_file_priv.php
$dir[] = 'user';
$dir_subdir['temp'][] = 'temp/compiled/user';
$tpl_dirs[] = 'temp/compiled/user';
admin/includes/init.php
define('ROOT_PATH', str_replace('user/includes/init.php', '', str_replace('\\', '/', __FILE__)));
require(ROOT_PATH . 'user/includes/lib_main.php');
require(ROOT_PATH . 'user/includes/cls_exchange.php');
if (!file_exists('../temp/compiled/user'))
{
@mkdir('../temp/compiled/user', 0777);
@chmod('../temp/compiled/user', 0777);
}
$smarty->template_dir = ROOT_PATH . 'user/templates';
$smarty->compile_dir = ROOT_PATH . 'temp/compiled/user';
$admin_path = preg_replace('/:\d+/', '', $ecs->url()) . 'user';
api/client/includes/lib_api.php
require_once(ROOT_PATH.'user/includes/lib_main.php');
require_once(ROOT_PATH . 'user/includes/cls_exchange.php');
require_once(ROOT_PATH . 'user/includes/lib_goods.php');
includes/cls_ecshop.php
function url()
{
$curr = strpos(PHP_SELF, 'user/') !== false ?
preg_replace('/(.*)(user)(\/?)(.)*/i', '\1', dirname(PHP_SELF)) :
dirname(PHP_SELF);
$root = str_replace('\\', '/', $curr);
if (substr($root, -1) != '/')
{
$root .= '/';
}
return $this->get_domain() . $root;
}
来源:中国B4C电子商务
最近更新
常用插件
- ecshop退款插件2.7.1utf版
ecshop退款插件2.7.1utf版重要可以通过会员中心,会员在收到货之后,发现...
- ecshop后台商品列表编辑属
ecshop后台商品列表编辑属性规格,这个功能十分重要,当我们在后台,录...
- ecshop二次开发打印采购单
在ecshop电子商务系统的开发和使用过程中,我们常常要统计订单的信息...
- ecshop整合招商银行php支付
最近有个朋友,他是用ecshop的。为了和招商银行合作,必须开发出基于...
- ecshop留言板改进
ecshop留言板 改进,这个插件主要是为了改进ecshop留言板功能插件,我们可...