How to add a new Social Media provider on user's settings?

How to add a new social media provider to user settings?

If you want to add a new Social Media provider to user settings, please proceed as follow:

Go to cPanel > FTP > File Manager > public-html > wp-content > themes > wpjobster-child > Edit ‘functions.php’

> Add below written code > Save changes

Add YouTube

add_filter( 'user_social_media_providers_filter', function( $providers ) {
	$providers['youtube'] = array( 'name' => __( 'Youtube', 'wpjobster' ), 'icon' => 'youtube' );
	return $providers;
});

Add Snapchat

add_filter( 'user_social_media_providers_filter', function( $providers ) {
	$providers['snapchat'] = array( 'name' => __( 'snapchat', 'wpjobster' ), 'icon' => 'snapchat' );
	return $providers;
});

If you want to add 2 or multiple Social Media, please put the code as below:

add_filter( 'user_social_media_providers_filter', function( $providers ) {
	$providers['youtube'] = array( 'name' => __( 'Youtube', 'wpjobster' ), 'icon' => 'youtube' );
	$providers['snapchat'] = array( 'name' => __( 'Snapchat', 'wpjobster' ), 'icon' => 'snapchat' );
	$providers['messenger'] = array( 'name' => __( 'Messenger', 'wpjobster' ), 'icon' => 'messenger');
	
	return $providers;
});

The Social Media can be filled in User’s profile > Settings > Social Media > Save Change

After filling them, they will be displayed as follows on Public Profile