wordpress水土不服的厉害,不得不去掉一些东西啦
1.去掉emoji
东西是好,但是中国没法用,只好忍痛去掉啦
remove_action( 'admin_print_scripts', 'print_emoji_detection_script'); remove_action( 'admin_print_styles', 'print_emoji_styles'); remove_action( 'wp_head', 'print_emoji_detection_script', 7); remove_action( 'wp_print_styles', 'print_emoji_styles'); remove_filter( 'the_content_feed', 'wp_staticize_emoji'); remove_filter( 'comment_text_rss', 'wp_staticize_emoji'); remove_filter( 'wp_mail', 'wp_staticize_emoji_for_email');
2.禁用google字体
function remove_open_sans() { wp_deregister_style( 'open-sans' ); wp_register_style( 'open-sans', false ); wp_enqueue_style('open-sans',''); } add_action( 'init', 'remove_open_sans' );
3.禁用avatar
禁止avatar头像已经不需要我们在代码里面更改啦,只需要在主题里面设置就ok
在设置->讨论 的头像里面去掉头像勾选就可以了
你可能还喜欢下面这些文章
在使用php的时候,我很少用到print这个函数,哦,不对,这是一个语言结构,而并非日函数!看一段代码
赞赏微信赞赏
支付宝赞赏