Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
<?php
/*
Plugin Name: bbPress - Custom User Contact Profile Fields
Plugin URI: https://gist.github.com/ntwb/c70caf5a0aa9d3062a6d
Description: bbPress - Custom User Contact Profile Fields
Version: 0.1
Author: Stephen Edgar - Netweb
Author URI: http://netweb.com.au
*/
// http://generatewp.com/user-contact-methods/
// http://codex.wordpress.org/Plugin_API/Filter_Reference/contactmethods
// Register User Contact Methods
function custom_user_contact_methods( $user_contact_method ) {
$user_contact_method['facebook'] = __( 'Facebook Username', 'text_domain' );
$user_contact_method['twitter'] = __( 'Twitter Username', 'text_domain' );
$user_contact_method['gplus'] = __( 'Google Plus', 'text_domain' );
$user_contact_method['skype'] = __( 'Skype Username', 'text_domain' );
/* Remove user contact methods */
unset( $user_contact['aim'] );
unset( $user_contact['jabber'] );
return $user_contact_method; ;
}
// Hook into the 'user_contactmethods' filter
add_filter( 'user_contactmethods', 'custom_user_contact_methods' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.