禁用Google网络字体提高网站加载速度
Update: WordPress 技巧:禁用 Google Fonts,加快 WordPress 后台打开速度:将下面的代码放到当前主题的 functions.php 文件: 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; } 最近,Google在国内访问拜GFW神威而抽风,不仅仅是Google的搜索和GMail邮件服务,其它的Google相关服务也受到影响,比如Google Font网络字体。 ...