Skip to content

Instantly share code, notes, and snippets.

@nmedia82
Last active October 9, 2016 03:35
Show Gist options
  • Save nmedia82/b7b3c765284ba3eede1ed063a54f5292 to your computer and use it in GitHub Desktop.
Save nmedia82/b7b3c765284ba3eede1ed063a54f5292 to your computer and use it in GitHub Desktop.
Adding Profile Tab in Ultimate Member Plugin to show Member Uploaded Files on Frontend
// this will add tab heading
add_filter('um_profile_tabs', 'user_files', 1000 );
function user_files($tabs) {
$tabs['userfiles'] = array(
'name' => 'My Files', // you can change this
'icon' => 'um-faicon-file', // you can change this
);
return $tabs;
}
// this will actually render the file uploader section
add_action('um_profile_content_userfiles_default', 'userfiles_content');
function userfiles_content() {
// you should not change anything here unless you know
echo apply_filters( 'the_content',' [nm-wp-file-uploader] ');
}
@nmedia82
Copy link
Author

nmedia82 commented Oct 8, 2016

Please visit this link for more detail:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment