去评论
dz插件网

[discuzX3.5] 后台修改代码加快加载速度

饾暦饾枎饾枒饾枏饾枂饾枅饾枑
2023/04/21 15:53:54
4、去掉”新闻动态“  
 source/admincp/admincp_index.php第404行找到 function show_news()函数,直接返回 return;
3、去掉”DiscuzX 开发团队“
 source/admincp/admincp_index.php第457行找到 show_forever_thanks() 函数,直接返回 return;

2、去掉版本检测   source/admincp/admincp_index.php第50-60行
$newversion = (CHARSET == 'utf-8') ? dunserialize($_G['setting']['cloudaddons_newversion']) : json_decode($_G['setting']['cloudaddons_newversion'], true);
if(empty($newversion['newversion']) || !is_array($newversion['newversion']) || abs($_G['timestamp'] - $newversion['updatetime']) > 86400 || (isset($_GET['checknewversion']) && $_G['formhash'] == $_GET['formhash'])) {
 $newversion = json_decode(cloudaddons_open('&mod=app&ac=upgrade'), true);
 if(!empty($newversion['newversion'])) {
   $newversion['updatetime'] = $_G['timestamp'];
   C::t('common_setting')->update_setting('cloudaddons_newversion', ((CHARSET == 'utf-8') ? $newversion : json_encode($newversion)));
   updatecache('setting');
 } else {
  $newversion = array();
 }
}
改为: $newversion = array();

1、修改后台首页“管理团队留言”中30天
 source/admincp/admincp_index.php第267行函数 function show_note()方法:
 $note['expiration'] = ceil(($note['expiration'] - $note['dateline']) / 86400);
或者直接让此函数 return;