MyBB Community Forums

Full Version: MyBB Avatars
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I'm hoping one of you experts can help me solve this problem I'm having. I want to display a users avatar on a page outside my forum directory. I'm extracting the avatar info from the database but noticed that there are three methods. I can't simply put an img tag and call that column from the database because it displays three different ways depending on how the user selected an avatar.

upload = "./uploads/avatar/avatar_001.jpg"
link = "http://www.domain.com/image.jpg"
gallery = "images/avatar/image.jpg"

Basically I just wanted to know how you would go about filtering this stuff so that it would show the image no matter what method they used. Any suggestions? Any help is appreciated.
Nevermind. I noticed that it also has a column for avatar type. That will do the job fine for me. I tried to delete this topic but I dont have permission. If someone else could do it that would be great!