HTML Logo by World Wide Web Consortium (www.w3.org). Click to learn more about our commitment to accessibility and standards.

Moving forward with Composr

ocPortal has been relaunched as Composr CMS, which is now in beta. ocPortal 9 will be superseded by Composr 10.

Head over to compo.sr for our new site, and to our migration roadmap. Existing ocPortal member accounts have been mirrored.


[BUG] {$AVATAR} Symbol Doesn't Show *Uploaded* Avatar

Login / Search

 [ Join | More ]
 Add topic 
Posted
Rating:
#35148 (In Topic #7943)
Joe
Avatar

Honoured member

ocPortal version 3.2.4 & IPB version 2.2

I noticed the {$AVATAR} symbol only gets the users avatar if they've linked to it using a URL. If the user chooses to upload their own avatar, ocPortal doesn't display an avatar at all when the symbol is used. :/

Back to the top
 
Posted
Rating:
#35171
Avatar

(This'll be related to the IPB2 forum driver)

It's just blank? I'd be surprised if it was completely blank - I'd expect it to be a broken URL. If you're using Firefox, try in IE and see if it shows as broken (Firefox skips missing images rather than showing error icons).


Become a fan of ocPortal on Facebook or add me as a friend. Add me on on Twitter.
Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about ocPortal whenever you see the opportunity.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying ocPortal on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Back to the top
 
Posted
Rating:
#35187
Joe
Avatar

Honoured member

It's actually broken! :P

ocPortal has the correct filename of the avatar, but the path is way off. Here's the path:

Code

/forums/html/avatars/av-18.jpg

I'm amazed to see ocPortal do this, seeing as even IPB 1.3 didn't have an /html/ directory (not that I remember).

So, how can I change the path ocPortal looks in for the avatar?

Back to the top
 
Posted
Rating:
#35195
Avatar

Community saint

Joe said

It's actually broken! :P

ocPortal has the correct filename of the avatar, but the path is way off. Here's the path:

Code

/forums/html/avatars/av-18.jpg

I'm amazed to see ocPortal do this, seeing as even IPB 1.3 didn't have an /html/ directory (not that I remember).

So, how can I change the path ocPortal looks in for the avatar?

I agree.

I run http://otakuplayground.com and am hopping to make themes and other things for ocportal even though I no longer use it for otakuplayground.com I still love it and feel it could go far with the right help. It needs themes and needs people to advertise for it.
Back to the top
 
Posted
Rating:
#35209
Avatar

IPB 1.3 did use this directory, but since IPB 2 it has changed. Please change the reference to 'html/avatars' on line 166 of sources/forum/ipb2.php to 'style_avatars'.
This will also be included as a bug fix in the next patch release.


Become a fan of ocPortal on Facebook or add me as a friend. Add me on on Twitter.
Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about ocPortal whenever you see the opportunity.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying ocPortal on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Back to the top
 
Posted
Rating:
#35210
Avatar

Community saint

sounds like a good idea.
This bug means 4 is a ways off yet.
I am expecting it next year some time.
LIke when IPB 3.0 comes out.

I run http://otakuplayground.com and am hopping to make themes and other things for ocportal even though I no longer use it for otakuplayground.com I still love it and feel it could go far with the right help. It needs themes and needs people to advertise for it.
Back to the top
 
Posted
Rating:
#35214
Joe
Avatar

Honoured member

If anyone is trying to fix this problem on their site too, this is what you want to do:

1. Open sources/forum/ipb2.php

2. Find (around line 331):

Code (php)

elseif ((url_is_local($avatar)) && ($avatar!='')) $avatar=get_forum_base_url().'/html/avatars/'.$avatar;

3. Replace with:

Code (php)

elseif ((url_is_local($avatar)) && ($avatar!='')) $avatar=get_forum_base_url().'/uploads/'.$avatar;

I made a slight modification to Chris's post as the line is actually on line 331 (or so it was in mine). Also, the uploaded avatars are actually stored in /uploads/. Avatars in the /style_avatars/ directory are just community packs that come with IPB.

EDIT: Apologies. The line is on line 166. For some reason my files have whitespace in them. :/


Last edit: by Joe

Back to the top
 
Posted
Rating:
#35223
Avatar

Community saint

The only problem I see with that is that there might be some members who use those avvys.
I actually installed a lot of avatars and people do use them so that would not work for me.

I run http://otakuplayground.com and am hopping to make themes and other things for ocportal even though I no longer use it for otakuplayground.com I still love it and feel it could go far with the right help. It needs themes and needs people to advertise for it.
Back to the top
 
1 guests and 0 members have just viewed this: None
Control functions:

Quick reply   Contract

Your name:
Your message: