![]() |
Prepared Avatar URL or Thumbnail
Is there anyway to get the $prepared[avatarurl] or a user's thumbnail avatar in another template besides the Member Info Templates? And can it be done with just a template edit and without the need for a plugin or product?
|
I've been unable to find any other way to access it (that's not to be said there isn't a way).
As it seems the only way I think you'll be able to get it is with a plugin, but I still don't know any defined variables that store it. |
There is no way to do this without plugins or file edits. If you are wanting to fetch the current user's avatar, set the "AVATAR_ON_NAVBAR" constant to true and use fetch_avatar_from_userinfo(). If you are wanting to fetch another user's avatar, use fetch_avatar_url().
See functions_user.php for both functions. |
That's too bad. I was hoping to pull the thumbnail as part of a style. Can the regular avatar be displayed using just the style? It seemed I did this once before but I can't seem to find where I tired it.
|
Quote:
|
Hrm, looks like I'll have to breakdown and delve into a working plugin if I want this to work the way I want. This is new territory for me.
I found the fetch_avatar functions, but where is this AVATAR_ON_NAVBAR constant exactly? |
You define it as true at init_startup.
PHP Code:
|
Oh, I see. The hook. I'm having trouble understanding how I tie it all together. I guess continued PHP tutorials are in order?
|
A handy tool is a mass search tool (I personally use Actual Search & Replace). Search for "AVATAR_ON_NAVBAR" and you will see what it does.
|
All times are GMT. The time now is 05:27 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|