
wordpress 字段
Upon the release of WordPress 2.9, we shared with you an article that shows you how to add fields like twitter and facebook to author profile page. In this article we will show you how you can remove unwanted default author profile fields to make WordPress admin panel more user friendly for your clients.
在WordPress 2.9发行后,我们与您分享了一篇文章,向您展示了如何将Twitter和Facebook之类的字段添加到作者个人资料页面 。 在本文中,我们将向您展示如何删除不需要的默认作者个人资料字段,以使WordPress管理面板对客户更友好。

As you can see, we do not want to keep AIM, Yahoo IM, and Jabber/Gtalk. If you are dealing with very new level clients, then you do not want them to see this. It will only complicate things for them. To remove these default fields simply open your theme’s functions.php file and add the following code:
如您所见,我们不想保留AIM,Yahoo IM和Jabber / Gtalk。 如果您要与非常新的客户打交道,那么您不希望他们看到这一点。 它只会使他们的事情复杂化。 要删除这些默认字段,只需打开主题的functions.php文件并添加以下代码:
<?php
add_filter('user_contactmethods','hide_profile_fields',10,1);
function hide_profile_fields( $contactmethods ) {
unset($contactmethods['aim']);
unset($contactmethods['jabber']);
unset($contactmethods['yim']);
return $contactmethods;
}
?>
This will remove the contact methods like AIM, Jabber, and Yahoo IM. Now if you want to add fields then you should check out our article that talks about adding author profile fields in WordPress.
这将删除诸如AIM,Jabber和Yahoo IM之类的联系方式。 现在,如果您想添加字段,那么您应该查看我们的文章,该文章讨论了在WordPress中添加作者个人资料字段 。
Source: Strangework by Brad Williams
资料来源: 布拉德·威廉姆斯的《怪异作品》
翻译自: https://www.wpbeginner.com/wp-tutorials/how-to-remove-default-author-profile-fields-in-wordpress/
wordpress 字段