How to Add Extra Contact Info or Remove Existing Info from WordPress


/ Published in: PHP
Save to your folder(s)

Here is one more field which you may want to add to use in Authors profile display and that is for gender. Gender info you can later use to write “His/He” or “Her/She” in general description. For this just add something like this in above mentioned code -
Code Example:

// Add Gender
$contactmethods['sex'] = 'Sex (male/female)';


Copy this code and paste it in your HTML
  1. function add_myExtra_ContactMethod( $contactmethods ) {
  2. // Add Twitter
  3. $contactmethods['twitter'] = 'Twitter';
  4. // Add Facebook
  5. $contactmethods['facebook'] = 'Facebook';
  6.  
  7. //Remove Jabber / Google Talk
  8. unset($contactmethods['jabber']);
  9.  
  10. return $contactmethods;
  11. }
  12.  
  13. add_filter('user_contactmethods','add_myExtra_ContactMethod',10,1);

URL: http://www.readers-cafe.net/2011/01/how-to-add-extra-contact-info-or-remove-existing-info-from-wordpress/

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.