1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.5 Admin User Search Criteria 'Has Avatar'

Discussion in 'XenForo Questions and Support' started by MRaburn, Sep 27, 2015.

  1. MRaburn

    MRaburn Active Member

    Hey guys,

    Been digging around for a while and maybe someone here knows the answer. I am pruning/moderating our user avatars. We have 170k users and basically only about 5% have avatars that need to be looked at and moderated. Currently this is very painful for obvious reasons.

    Is there a way to pass a Criteria in the URL to only return users that DO have an Avatar?

    I know there is this:


    I just do not know if there is one that will check the $user['avatar_date'] or $user['gravatar'] to see if Not Empty.

    Thanks for any tips! Would save me about 30 hours of work.
  2. Jeremy

    Jeremy XenForo Moderator Staff Member

    There isn't a built in search criteria for this. It may be available via an add-on.
  3. James

    James Well-Known Member

    You could find the users via the avatar directory under /data/. Each avatar name is the user id of the user who has that avatar.

    Not the best method but it works!
  4. MRaburn

    MRaburn Active Member

    Thanks for your input guys. I'll see what I can come up with, I saw an addon to add this Criteria to the Trophy system, see if I can cross if over to the User list.
  5. Chris D

    Chris D XenForo Developer Staff Member

    Create a user group promotion using the "Does not have an avatar" criteria. Any users NOT in that specified group has an avatar.
    James likes this.
  6. MRaburn

    MRaburn Active Member

    Well that right there is an AWESOME idea. Thanks Chris!
  7. MRaburn

    MRaburn Active Member

    @Chris D it seems my user promotion is running at a limit of 20 user upgrades per cron run. Is there somewhere in the code or settings I can increase this? Will take a long time to run through 170k members. ;)
  8. Chris D

    Chris D XenForo Developer Staff Member

    Yeah that will take forever - and it will only do active users, that way, too.

    You will want to use the Rebuild User Group Promotions tool on the Admin CP > Tools > Rebuild Caches page... which will still take forever, but at least it does it in one go ;)
  9. MRaburn

    MRaburn Active Member

    Thanks Chris! This method seems will give me some good ideas by using promotions and upgrades to find certain classes of users and act on it.

Share This Page