User Profile Picture Plugin WordPress, Download, Install
Set a custom profile image for a user using the standard WordPress media upload tool.
User Profile Picture Download Now
(If the link does not work)↓
Originals Link WordPress.org
https://wordpress.org/plugins/metronet-profile-picture/
How to Install User Profile Picture Plugin, Manually
- Upload
metronet-profile-picture
folder to the/wp-content/plugins/
directory - Activate the plugin through the ‘Plugins’ menu in WordPress
- Place
<?php mt_profile_img() ?>
in your templates (arguments and usage are below) - Use the “Override Avatar” function to change your default avatar.
Arguments:
/** * mt_profile_img * * Adds a profile image * @param $user_id INT - The user ID for the user to retrieve the image for @ param $args mixed size - string || array (see get_the_post_thumbnail) attr - string || array (see get_the_post_thumbnail) echo - bool (true or false) - whether to echo the image or return it */
Example Usage:
<?php //Assuming $post is in scope if (function_exists ( 'mt_profile_img' ) ) { $author_id=$post->post_author; mt_profile_img( $author_id, array( 'size' => 'thumbnail', 'attr' => array( 'alt' => 'Alternative Text' ), 'echo' => true ) ); } ?>
View the code on Pastebin.
The mt_profile_img
function internally uses the get_the_post_thumbnail function to retrieve the profile image.
Optionally, if you choose the “Override Avatar” function, you can use get_avatar to retrieve the profile image.
If you want the “Override Avatar” checkbox to be checked by default, drop this into your theme’s functions.php
file or Site-specific plugin:
add_filter( 'mpp_avatar_override', '__return_true' );
If you want to hide the “Override Avatar” checkbox, use this filter (the override functionality will be enabled by default):
add_filter( 'mpp_hide_avatar_override', '__return_true' );
The REST API is currently supported for versions of WordPress 4.4 and up.
The endpoint is: http://www.yourdomain.com/wp-json/mpp/v1/user/{user_id}
If a profile picture is found, it’ll return JSON as follows:
{"attachment_id":"3638","attachment_url":"http://localhost/ronalfy/wp-content/uploads/2015/12/Leaderboard-All-Time.png"}
Video
Screenshots
Plugin Not Working?
If any errors or problems with the plug-in then write comments.
Related:
- Choosing a web server operating mode based on…
- Interview With The Master And Artist Of Cross-Stitch
- Questions To Ask In An Interview
- Choosing a WordPress caching plugin: benchmarking 18 plugins
- What is Infolinks.com?
- WordPress plugins for bitcoin and cryptocurrencies
- Owner of the GudStory Blog. Webmaster From India.…
- Peter Shepherd (Trans4mind.com) Webmaster From The…
Related Posts
Gravitate Event Tracking Plugin WordPress, Download, Install
Embed Google Map Plugin WordPress, Download, Install
FB Cache Cleaner Plugin WordPress, Download, Install
About The Author
admin
I am are a 5 years has been a freelancer, engaged in web design, website building.