[FAQ] Guide to avatars

This is an archive of the phpBB 2.0.x support forum. Support for phpBB2 has now ended.
Forum rules
Following phpBB2's EoL, this forum is now archived for reference purposes only.
Please see the following announcement for more information: viewtopic.php?f=14&t=1385785
Locked
User avatar
Black Fluffy Lion
Former Team Member
Posts: 6057
Joined: Sat Dec 15, 2001 11:37 am

[FAQ] Guide to avatars

Post by Black Fluffy Lion » Wed Apr 24, 2002 6:25 pm

New link to the Knowledge Base

Handy Dandy Guides Present...

Guide to avatars!

Contents
  • Introduction
    • So what's an 'avatar'?
    • Right, where can I get avatars then?
    • OK then hotshot, what are all these different types of avatars with phpBB2?
      • Gallery avatars
      • Remote avatars
      • Uploaded avatars
    • So how do I use them then?
  • Admin panel
    • What's all this about doing avatars under the admin panel?
    • So what do all these options mean?
      • Enabling forms of avatar selection
      • Maximums
      • Paths
    • I've done all that. Now what?
  • Files
    • Where do I put what?
  • Editing your profile
    • So how do I display my avatar now?
      • Remote avatars
      • Gallery avatars
      • Uploaded avatars
    • That's all?
  • Troubleshooting
    • My avatar doesn't show up/gallery doesn't display! *whimper*
      • Yes! Please tell me how to fix it!
      • CH-what?
    • When my users register their avatar doesn't show up so they have to go back to edit it again. Any fix?
    • When I try changing my avatar from a remote or gallery avatar to an uploaded one all I get is error messages. You wanna solve this one too?
    • Why does the category select thing display all strange?
    • It still doesn't work!
  • End note
Introduction

Avatars, avatars, avatars...they hold so many joys yet can be so annoying when they don't work. I've seen many a folk crumble when faced with the daunting of changing their avatar. What options to change?? What to CH-MOD?? How to enable uploads?? Well, hopefully this tutorial will answer all of these questions, so you will know all there is to be known about avatars. Sounds pretty exciting, huh?? No?! Read on anyway.

So what's an 'avatar'?

OK, let's start with the basics. An avatar is the image that is displayed (if enabled and specified) below the user's name in topics, just below their rank. It also shows up when you view a members profile.

Right, where can I get avatars then?

Try http://www.bbaddons.com/as/pafiledb.php ... egory&id=1

OK then hotshot, what are all these different types of avatars with phpBB2?

With phpBB2 there's 3 main ways to select an avatar - gallery, uploading and linking. I'll explain what each of them is here:

Gallery avatars

This is where there is a collection of avatars already on the server. You can select one from the gallery. The gallery is often split into sections (e.g. Simpsons, Futurama, Other).

Remote avatars

This is where there is the avatar you want uploaded to a different server. You use this by linking to the avatar's URL.

Uploaded avatars

This is where you can select a file on your computer to upload to the server to use as your avatar. You can also select a file on a different server to be copied to the fora's server.

So how do I use them then?

Whoah! Patience, I'm just getting to that part! Before you can select an avatar in your profile you'll have to do a few things in the admin panel, so I'll explain that now.

Admin panel

What's all this about doing avatars under the admin panel?

Well before you can do anything with avatars you'll have to enable them. So trot on over to the admin panel (link at the bottom of the page in case you hadn't already noticed it) and go to 'Configuration', under 'General Admin'. Scroll down the page and you'll hit 'Avatar Settings'. Ding ding ding! Congratulations, you've reached avatar country.

So what do all these options mean?

Let's start at the top...

Enabling forms of avatar selection

That's what the first 3 options are, pretty self-explanitory. 'Enable gallery avatars', 'Enable remote avatars' and 'Enable avatar uploading' are for you to state whether you wish to allow those forms of avatar selection. And since you know what all of those are, because cleverly you read the introduction section, this should be no problem to deal with.

Maximums

This is what we get to next: 'Maximum Avatar File Size' and 'Maximum Avatar Dimensions'. Also pretty self-explanitory. But why do you want these limits?? Well, let me put it this way, do you want some prat uploading a 2 MB gif that takes up all the space on the screen, pushes the user column so far out you have to scroll to read any message, takes up half your server space and stretches their profile out so far to the right that it screws up your whole fora? I rest my case. Note that these limits do not apply to remotely linked avatars so if you leave that enabled then you can still get some prat using a 2 MB gif that takes up all the space on the screen etc...

Paths

Scroll down a wee bit more and you hit the world of paths, in this case 'Avatar Storage Path' and 'Avatar Gallery Path'. This is where the location of all your gallery and uploaded avatars is specified. You can change this if you want avatars uploaded and the gallery to be sotred in a different location but remember to make the same changes to your site's FTP! But, if you are lazy, like me, then just leave it on the default (images/avatars and images/avatars/gallery).

I've done all that. Now what?

When you've twiddled with those settings to your heart's content then it's time to specify the avatar in your profile. Carry on reading...

Files

Where do I put what?

If you're using gallery avatars then obviously you'll need them on the server if you want your users to select one. With a FTP client go to the place you selected under 'Avatar Gallery Path', and create a new folder in it. This will be the name of one of the categories. Upload the right avatars to there, and make more categories if you want. CH-MOD these files 777 (see Troubleshooting --> My avatar doesn't show up/gallery doesn't display! *whimper* for more).

Editing your profile

So how do I display my avatar now?

Click on 'Profile' (there's a link at the top of the forum page) and scroll again. You'll come across a little something called 'Avatar control panel'. Ding ding ding! We're back in avatar country. First of all you'll see the avatar you're currently using. Now this next bit is so freaking easy I honestly don't know why I'm explaining it. Oh well, here goes:

Remote avatars

This is the bit next to 'Link to off-site Avatar'. All you have to do (I feel like an idiot explaining this) is, as it says, 'Enter the URL of the location containing the avatar image you wish to link to.' Couldn't be easier.

Gallery avatars

Now we come across 'Select Avatar from gallery'. This is also amazingly easy to do. Just hop over to the gallery with the 'Show gallery' link, select the avatar you want and then click 'Select avatar'. Note that there may be different categories to browse in; so to change the category you're viewing just change the 'Select category' drop down list (near the top).

Uploading avatars

There's 2 different ways to do this now. Firstly, 'Upload Avatar from your machine'. To use this just click the 'Browse' button and you'll find yourself with a way to navigate around your computer and select the avatar you want. The other way, 'Upload Avatar from a URL' is simple enough. It's basically the same as the link to off-site avatar option exept this time instead of just linking to it, it copies the avatar file to the server and uses that copy.

That's all?

Yep, done! What, it doesn't work?? Well, there's always a problem or two...

Troubleshooting

My avatar doesn't show up/gallery doesn't display! *whimper*

Sigh...a problem?? Well, the good news is that I expect there's an easy fix...

Yes! Please tell me how to fix it!

That's not a question and this is an FAQ. But neither was the last question a question so I'll help you anyway. Chances are the problem is that the permissions are wrong so your fora does not have permission to display the avatar. To change this all we have to do is CH-MOD the avatar directory and files 777.

CH-what??

If you're using a good FTP client - I recommend SmartFTP - and are running phpBB2 on Unix then this will be very easy. First, locate the avatar files and directory and select them. Then right click on them and select 'Properties' or 'CHMOD' or 'Permissions' or something like that. You want to CH-MOD them 777. If there's no space to enter this as a number then you want to enable everyone access to write, read and execute the file (in most cases this can be done by ticking all the boxes). Done!

When my users register their avatar doesn't show up so they have to go back to edit it again. Any fix?

Pretty annoying...luckily there is a fix:

Open up /includes/usercp_avatar.php and find

Code: Select all

return ( $mode == 'editprofile') ? ", user_avatar = '" . str_replace("\'", "''", $avatar_filename) . "', user_avatar_type = " . USER_AVATAR_GALLERY : '';
...replace this with

Code: Select all

return ( $mode == 'editprofile' ) ? ", user_avatar = '" . str_replace("\'", "''", $avatar_filename) . "', user_avatar_type = " . USER_AVATAR_GALLERY : "'$avatar_filename', " . USER_AVATAR_GALLERY;
Should fix the problem!

When I try changing my avatar from a remote or gallery avatar to an uploaded one all I get is error messages. You wanna solve this one too?

T'would be my pleasure to. Try deleting your current avatar first and then uploading your new one. A simple fix but often works. If it doesn't though then try this:

Open up /includes/usercp_avatar.php and find the code

Code: Select all

$new_filename = ( $current_avatar != '' && $mode != 'register' ) ? $current_avatar : uniqid($user_ip) . $imgtype;
...and replace this with

Code: Select all

$new_filename = uniqid($user_ip) . $imgtype; 
Why does the category select thing display all strange?

There are bugs with some themes which cause the category select menu to not display properly. Luckily for you, this fix should work but backup the file first! Open templates/yourTemplate/profile_avatar_gallery.tpl and change your category code to

Code: Select all

	<tr> 
	  <td class="catBottom" align="center" valign="middle" colspan="6" height="28"><span class="genmed">{L_CATEGORY}:&{S_CATEGORY_SELECT}&<input type="submit" class="liteoption" value="{L_GO}" name="avatargallery" /></span></td>
	</tr>
It would also be helpful to inform the template creator of the bug if s/he does not already know about it.

It still doesn't work!

Ask in this thread then and I'll try to help you and add it to this section.

End note

That's it again from Handy Dandy Guides. Hope you found it useful. As ever, feedback is appreciated. The troubleshooting section will be updated with any questions I see or you ask here. And to round it all off, a few thank-yous: to Brewjah, for the link to the avatar site; to The Black Pit for sticking it; to Sven Ansem, for finding the fix to the gallery avatars don't show up after registration problem; to themidnightclub, for his fix on the moving to an uploaded avatar problem; to the phpBB2 team, for making such a great bit of software; and lastly, to you, for reading it.

Keywords: avatar picture image graphic under name username change edit remote link off-site upload gallery file problem trouble category chmod ch mod ch-mod 777 permission read write execute
Last edited by Black Fluffy Lion on Tue Jun 25, 2002 7:28 pm, edited 2 times in total.

jet_Jaguar
Registered User
Posts: 63
Joined: Sat Apr 06, 2002 10:53 pm
Location: Central California, USA

Post by jet_Jaguar » Wed Apr 24, 2002 9:04 pm

Nice work, BFL, but I'd add something about chmod being a unix thing, in case people with windows servers get confused. Still, that's a nice tutorial.

Pit
Security Consultant
Posts: 2056
Joined: Sat Oct 13, 2001 8:17 pm
Location: kµlt øƒ Ø™
Contact:

Post by Pit » Wed Apr 24, 2002 9:08 pm

Stixx0r3d. :P

Image
Image
super fun rainbow colour sig

talia679
Registered User
Posts: 716
Joined: Tue Mar 12, 2002 4:07 pm
Location: PA
Contact:

Post by talia679 » Thu Apr 25, 2002 2:57 pm

Okay I need more help!

http://www.phpbb.com/phpBB/viewtopic.php?t=13719

That is the link to the post I have had up for a while ...

This is what it said:
I did my searching ... and there are a lot of people with Avatar problems ... I haven't found one message with my problem yet ... if there was one point me too it please !!

Here's the problem. When a person registers and picks an avatar from the gallery their avatar will not show up in their profile unless they go back and edit their profile again.

Does this make sense?
Thanks, Talia
Tag You're It Writing Community || TYI Forums
Taleria - Talia's Gallery of 2000+ Links & 140+ Books
GameCrafters Guild – Gaming info and resources

User avatar
Black Fluffy Lion
Former Team Member
Posts: 6057
Joined: Sat Dec 15, 2001 11:37 am

Post by Black Fluffy Lion » Thu Apr 25, 2002 3:40 pm

Jet_Jaguar wrote: Nice work, BFL, but I'd add something about chmod being a unix thing, in case people with windows servers get confused. Still, that's a nice tutorial.


thanks...added it to my to do list...
Stixx0r3d.


ta Pit. And I got the moderatoring tool!

talia - will look at in a minute

Kickinchicken
Registered User
Posts: 1
Joined: Thu Apr 25, 2002 4:12 pm

Post by Kickinchicken » Thu Apr 25, 2002 4:26 pm

I have tried everything, I mean everything. I would be will to pay someone to fix it. I just wish I could fix it to keep for going back to vbullentin. I like phpBB2, better, but ........

Biggs
Registered User
Posts: 142
Joined: Sat Aug 11, 2001 5:24 am
Location: Minneapolis
Contact:

Post by Biggs » Thu Apr 25, 2002 8:39 pm

I've tried everything as well, but I cant get my Avatar options to show up in people's profiles... Hmm?
Mordak
GamesNET Support Helper

ßeta dan
Registered User
Posts: 6
Joined: Mon Apr 22, 2002 7:50 pm

Post by ßeta dan » Thu Apr 25, 2002 10:44 pm

here is the problem that i am getting:

{Large screenshot removed by Black Fluffy Lion since it pushed the screen out wide. The problem has been fixed and darkBlue's files updated accordingly: http://www.phpbb.com/phpBB/viewtopic.php?t=14872 }

User avatar
Black Fluffy Lion
Former Team Member
Posts: 6057
Joined: Sat Dec 15, 2001 11:37 am

Post by Black Fluffy Lion » Fri Apr 26, 2002 5:09 pm

talia - does this problem only occur with gallery avatars??

Biggs - are all the avatar options missing?? try reuploading profile.php

ßeta dan - uhhh...what's exactly the problem??

ßeta dan
Registered User
Posts: 6
Joined: Mon Apr 22, 2002 7:50 pm

Post by ßeta dan » Fri Apr 26, 2002 5:21 pm

As you may well see the problem is that right under the "Avatar Gallery" heading the names of the folders are displayed on the page and not the drop box

User avatar
Black Fluffy Lion
Former Team Member
Posts: 6057
Joined: Sat Dec 15, 2001 11:37 am

Post by Black Fluffy Lion » Fri Apr 26, 2002 5:24 pm

ßeta dan - looks like a problem with the style. Try reuploading 'profile_avatar_gallery.tpl' in your templates directory.

ßeta dan
Registered User
Posts: 6
Joined: Mon Apr 22, 2002 7:50 pm

Post by ßeta dan » Fri Apr 26, 2002 5:42 pm

didn't work...thanx anyways

User avatar
Black Fluffy Lion
Former Team Member
Posts: 6057
Joined: Sat Dec 15, 2001 11:37 am

Post by Black Fluffy Lion » Fri Apr 26, 2002 5:48 pm

ßeta dan - I expect it's a problem with the style - try asking it's creator or anyone else who uses it. Check that in profile_avatar_gallery.tpl you have the following code:

Code: Select all

  <td class="catBottom" align="center" valign="middle" colspan="6" height="28"><span class="genmed">{L_CATEGORY}:&nbsp;{S_CATEGORY_SELECT}&nbsp;<input type="submit" class="liteoption" value="{L_GO}" name="avatargallery" /></span></td>
	</tr>

ßeta dan
Registered User
Posts: 6
Joined: Mon Apr 22, 2002 7:50 pm

Post by ßeta dan » Fri Apr 26, 2002 6:08 pm

Did that as well but it was in vien
Tweakers Forums

talia679
Registered User
Posts: 716
Joined: Tue Mar 12, 2002 4:07 pm
Location: PA
Contact:

Post by talia679 » Fri Apr 26, 2002 6:18 pm

Black Fluffy Lion wrote: talia - does this problem only occur with gallery avatars??


I only use Gallery Avatars on my forum ... so I haven't tried it any other way.
Thanks, Talia
Tag You're It Writing Community || TYI Forums
Taleria - Talia's Gallery of 2000+ Links & 140+ Books
GameCrafters Guild – Gaming info and resources

Locked

Return to “2.0.x Support Forum”