Title: Using Local Avatars
Last modified: August 30, 2016

---

# Using Local Avatars

 *  Resolved [zshann](https://wordpress.org/support/users/zshann/)
 * (@zshann)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/using-local-avatars/)
 * Hi I was wondering if it would be possible (or is possible) to use local avatars
   instead of Gravatar images in the user list?
 * Currently we host our avatars internally as we use our one wordpress installation
   as an intranet.
 * We do this with either the Avatar Manager Plugin ([https://wordpress.org/plugins/avatar-manager/](https://wordpress.org/plugins/avatar-manager/))
 * or with the Simple Intranet Directory Plugin (Which we are trying to replace 
   with AMR)
    ([https://wordpress.org/plugins/simple-intranet-directory/](https://wordpress.org/plugins/simple-intranet-directory/))
 * Currently when we try to point to those avatars in the lists, instead of showing
   the image it just reads off the URL and the code surrounding it.
 * Thank you in advance for your time.
 * [https://wordpress.org/plugins/amr-users/](https://wordpress.org/plugins/amr-users/)

Viewing 6 replies - 1 through 6 (of 6 total)

 *  Plugin Author [anmari](https://wordpress.org/support/users/anmari/)
 * (@anmari)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/using-local-avatars/#post-6484255)
 * Yes of course – if done properly as wordpress intends it works beautifully.
 * amr users plugin calls wp function get_avatar. Any plugin offering custom (local
   or remote) avatars should be using the get_avatar filter for easy seamless custom
   avatar. The avatar plugin’s filter function should then be looking up the appropriate
   local or remote custom avatar and returning that.
 * [https://codex.wordpress.org/Plugin_API/Filter_Reference/get_avatar](https://codex.wordpress.org/Plugin_API/Filter_Reference/get_avatar)
   (
   the sample in the codex is NOT the best because it has the id hardcoded, but 
   the principle is there.
 * THis page describes it better.
    [http://www.billerickson.net/wordpress-custom-avatar/](http://www.billerickson.net/wordpress-custom-avatar/)
 *  Thread Starter [zshann](https://wordpress.org/support/users/zshann/)
 * (@zshann)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/using-local-avatars/#post-6484454)
 * Hi again,
 * So based on the above (which thank you very much for pointing me in the right
   direction!)
 * Using the WP User Avatar plugin ([https://wordpress.org/plugins/wp-user-avatar/](https://wordpress.org/plugins/wp-user-avatar/)
   I was able to get the avatar meta field to display the users avatar when I view
   the user list in the dashboard under user lists > configure a list > [my current
   list] > View [under Name of List] section.
 * The problem I now have is when I try to put that list (simple or table) on a 
   page (either manually or by pressing the add page button) the pictures do not
   show up. They only show up if I view the page within the dashboard as mentioned
   above.
 * Am I missing something silly? or could another plugin causing an issue? Currently
   I just have the avatar meta field as display order 1, link type = none, and all
   other option fields are blank.
 * I feel like I’m missing something incredibly simple but I’m not sure what.
 * Thank you again for your help I really do appreciate it. 🙂
 *  Plugin Author [anmari](https://wordpress.org/support/users/anmari/)
 * (@anmari)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/using-local-avatars/#post-6484455)
 * There is also a page cache – have you refreshed the page (should have refreshed
   by now though)
 * The code for front and back is the same so if it displays in back it will be 
   calling same code in front – hence either it’s a cache thing,
    Or the called 
   function(avatar) behaves differently when called from front Or sometimes folks
   have other css that affects things – check whether the avatar html is being generated.
 *  Thread Starter [zshann](https://wordpress.org/support/users/zshann/)
 * (@zshann)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/using-local-avatars/#post-6484457)
 * Hi,
 * Just to give you an update, it does look like its generating the code on the 
   front page correctly, but its displaying the avatar as a 0x0 square in the upper-
   right hand corner of the post/page. Which explains why I thought they weren’t
   being added to the page.
 * Now the question is why they are displaying as 0x0 squares… lol Which I’m thinking
   is my problem. I’ve just been looking through my CSS to try to find what’s causing
   that. Because the AMR code looks perfect as shown below:
 * `<img src="http://my.website.com/wp-content/uploads/Default_UserIcon.png" width
   ="150" height="150" alt="" class="avatar avatar-150 wp-user-avatar wp-user-avatar-
   150 photo avatar-default" data-lazy-loaded="true" style="display: block;">`
 * It looks like it may have something to do with the theme I’m using (Colorlib’s
   Sparkling) because everything effecting the style of that object are in bootstrap.
   min.css / style.css (that aren’t from amrusersfront.css) which would come from
   Sparkling.
 * Thank you anmari for your help and for pointing me in the right direction. 🙂
 *  Plugin Author [anmari](https://wordpress.org/support/users/anmari/)
 * (@anmari)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/using-local-avatars/#post-6484458)
 * OK – sounds like maybe you haven’t discovered the joys of web development tools
   like either firebug (firefox) or chrome
    ‘inpect element’
 * should be able to see straight away which css is affecting, where it comes from.
   
   and you can untick / adjust the css realtime to debug/check
 * [http://www.sitepoint.com/inspect-element-troubleshooting-css-browser/](http://www.sitepoint.com/inspect-element-troubleshooting-css-browser/)
   
   [http://getfirebug.com/css](http://getfirebug.com/css) [https://developer.chrome.com/devtools/docs/elements-styles](https://developer.chrome.com/devtools/docs/elements-styles)
 *  Thread Starter [zshann](https://wordpress.org/support/users/zshann/)
 * (@zshann)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/using-local-avatars/#post-6484459)
 * Found it & Fixed. 🙂
 * For future reference if anyone else uses the Colorlib “Sparkling” theme and runs
   into this issue.
 * In Stylings CSS:
    .vcard .avatar { position: absolute; <—- Change to Static or
   Relative left: 20px; top: -80px; border-radius: 2px; }
 * That will at least make the pictures display for anyone using Sparkling, it still
   has some other styling issues that I worked out on my own, but they shouldn’t
   be show stoppers for anyone.
 * Thanks again!

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘Using Local Avatars’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/amr-users_f6f6f4.svg)
 * [amr users](https://wordpress.org/plugins/amr-users/)
 * [Support Threads](https://wordpress.org/support/plugin/amr-users/)
 * [Active Topics](https://wordpress.org/support/plugin/amr-users/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/amr-users/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/amr-users/reviews/)

 * 6 replies
 * 2 participants
 * Last reply from: [zshann](https://wordpress.org/support/users/zshann/)
 * Last activity: [10 years, 8 months ago](https://wordpress.org/support/topic/using-local-avatars/#post-6484459)
 * Status: resolved