ecshop后台如何去掉更新提醒,install、demo删除提醒
发布:smiling 来源: PHP粉丝网 添加日期:2014-06-19 11:18:56 浏览: 评论:0
首先找到如下文件admin\index.php
一:删除更新提醒:(大概483行左右)注释掉或者删掉下面的代码:
- elseif ($_REQUEST['act'] == 'main_api')
- {
- require_once(ROOT_PATH . '/includes/lib_base.php');
- $data = read_static_cache('api_str');
- if($data === false || API_TIME < date('Y-m-d H:i:s',time()-43200))
- {
- include_once(ROOT_PATH . 'includes/cls_transport.php');
- $ecs_version = VERSION;
- $ecs_lang = $_CFG['lang'];
- $ecs_release = RELEASE;
- $php_ver = PHP_VERSION;
- $mysql_ver = $db->version();
- $order['stats'] = $db->getRow('SELECT COUNT(*) AS oCount, IFNULL(SUM(order_amount), 0) AS oAmount' .
- ' FROM ' .$ecs->table('order_info'));
- $ocount = $order['stats']['oCount'];
- $oamount = $order['stats']['oAmount'];
- $goods['total'] = $db->GetOne('SELECT COUNT(*) FROM ' .$ecs->table('goods').
- ' WHERE is_delete = 0 AND is_alone_sale = 1 AND is_real = 1');
- $gcount = $goods['total'];
- $ecs_charset = strtoupper(EC_CHARSET);
- $ecs_user = $db->getOne('SELECT COUNT(*) FROM ' . $ecs->table('users'));
- $ecs_template = $db->getOne('SELECT value FROM ' . $ecs->table('shop_config') . ' WHERE code = \'template\'');
- $style = $db->getOne('SELECT value FROM ' . $ecs->table('shop_config') . ' WHERE code = \'stylename\'');
- if($style == '')
- {
- $style = '0';
- }
- $ecs_style = $style;
- $shop_url = urlencode($ecs->url());
- $patch_file = file_get_contents(ROOT_PATH.ADMIN_PATH."/patch_num");
- $apiget = "ver= $ecs_version &lang= $ecs_lang &release= $ecs_release &php_ver= $php_ver &mysql_ver= $mysql_ver &ocount= $ocount &oamount= $oamount &gcount= $gcount &charset= $ecs_charset &usecount= $ecs_user &template= $ecs_template &style= $ecs_style &url= $shop_url &patch= $patch_file ";
- $t = new transport;
- $api_comment = $t->request('http://api.ecshop.com/checkver.php', $apiget);
- $api_str = $api_comment["body"];
- echo $api_str;
- $f=ROOT_PATH . 'data/config.php';
- file_put_contents($f,str_replace("'API_TIME', '".API_TIME."'","'API_TIME', '".date('Y-m-d H:i:s',time())."'",file_get_contents($f)));
- write_static_cache('api_str', $api_str);
- }
- else
- {
- echo $data;
- }
二:install删除提醒:(大概182行左右)注释或删除下面代码:
- if (file_exists('../install'))
- {
- $warning[] = $_LANG['remove_install'];
- }
三:更新提醒:(大概187行)注释或删除代码:
- if (file_exists('../upgrade'))
- {
- $warning[] = $_LANG['remove_upgrade'];
- }
四:demo删除提醒:(大概192行)注释或删除下面代码:
- if (file_exists('../demo'))
- {
- $warning[] = $_LANG['remove_demo'];
- }
Tags: ecshop去掉更新提醒 删除提醒
推荐文章
热门文章
最新评论文章
- 写给考虑创业的年轻程序员(10)
- PHP新手上路(一)(7)
- 惹恼程序员的十件事(5)
- PHP邮件发送例子,已测试成功(5)
- 致初学者:PHP比ASP优秀的七个理由(4)
- PHP会被淘汰吗?(4)
- PHP新手上路(四)(4)
- 如何去学习PHP?(2)
- 简单入门级php分页代码(2)
- php中邮箱email 电话等格式的验证(2)