最美情侣中文字幕电影,在线麻豆精品传媒,在线网站高清黄,久久黄色视频

歡迎光臨散文網 會員登陸 & 注冊

使用wordpress后臺管理很慢怎么辦

2022-08-05 20:44 作者:好學習的Wade  | 我要投稿

wordpress網站后臺管理比較慢怎么辦

我們只需要將下面的代碼進行復制,然后粘貼進去,然后保存就可以了。

首先我們先找到外觀,主題文件編輯器


然后找到functions.php,找不到的話直接ctrl+f查找就可以啦,然后找到底部添加下面這些代碼:


/*禁用谷歌字體和頭像*/
function kratos_get_avatar( $avatar ) {
$avatar = preg_replace( “/http:\/\/(www|\d).gravatar.com/”,”http://cn.gravatar.com”,$avatar );
return $avatar;
}
add_filter( ‘get_avatar’, ‘kratos_get_avatar’ );

function coolwp_remove_open_sans_from_wp_core() {
wp_deregister_style( ‘open-sans’ );
wp_register_style( ‘open-sans’, false );
wp_enqueue_style(‘open-sans’,”);}
add_action( ‘init’, ‘coolwp_remove_open_sans_from_wp_core’ );

// 屏蔽谷歌字體
add_filter( ‘gettext_with_context’, ‘wpjam_disable_google_fonts’, 888, 4);
function wpjam_disable_google_fonts($translations, $text, $context, $domain ) {
$google_fonts_contexts = array(‘Open Sans font: on or off’,’Lato font: on or off’,’Source Sans Pro font: on or off’,’Bitter font: on or off’);
if( $text == ‘on’ && in_array($context, $google_fonts_contexts ) ){
$translations = ‘off’;
}

return $translations;
}

//屏幕谷歌的API

// 徹底關閉自動更新
add_filter(‘automatic_updater_disabled’, ‘__return_true’);
// 關閉更新檢查定時作業(yè)
remove_action(‘init’, ‘wp_schedule_update_checks’);

// 移除已有的版本檢查定時作業(yè)
wp_clear_scheduled_hook(‘wp_version_check’);

// 移除已有的插件更新定時作業(yè)
wp_clear_scheduled_hook(‘wp_update_plugins’);

// 移除已有的主題更新定時作業(yè)
wp_clear_scheduled_hook(‘wp_update_themes’);

// 移除已有的自動更新定時作業(yè)
wp_clear_scheduled_hook(‘wp_maybe_auto_update’);

// 移除后臺內核更新檢查
remove_action( ‘admin_init’, ‘_maybe_update_core’ );

// 移除后臺插件更新檢查
remove_action( ‘load-plugins.php’, ‘wp_update_plugins’ );
remove_action( ‘load-update.php’, ‘wp_update_plugins’ );
remove_action( ‘load-update-core.php’, ‘wp_update_plugins’ );
remove_action( ‘admin_init’, ‘_maybe_update_plugins’ );

// 移除后臺主題更新檢查
remove_action( ‘load-themes.php’, ‘wp_update_themes’ );
remove_action( ‘load-update.php’, ‘wp_update_themes’ );
remove_action( ‘load-update-core.php’, ‘wp_update_themes’ );
remove_action( ‘admin_init’, ‘_maybe_update_themes’ );

// 禁止古騰堡加載 Google 字體
add_action(‘admin_print_styles’, function(){
wp_deregister_style(‘wp-editor-font’);
wp_register_style(‘wp-editor-font’, ”);
});

最后一步,代碼全部復制完成之后,點擊更新文件就可以啦。


使用wordpress后臺管理很慢怎么辦的評論 (共 條)

分享到微博請遵守國家法律
盘锦市| 玉田县| 贡嘎县| 扬州市| 桓台县| 霍邱县| 兴城市| 沈阳市| 房产| 丹寨县| 沂南县| 南京市| 芮城县| 嘉定区| 唐海县| 临邑县| 沈阳市| 高唐县| 青神县| 象山县| 玛纳斯县| 云安县| 福安市| 新邵县| 偏关县| 休宁县| 于田县| 全南县| 新化县| 唐山市| 英德市| 和顺县| 清新县| 浦北县| 陈巴尔虎旗| 蕲春县| 柞水县| 佛坪县| 九龙县| 卓尼县| 昔阳县|