Support Forum

Avatars

AT Alex T
Alex T
Member

Is there a way I can make users avatars show up on the outside of the posts where you have this:

24 Answers

New Answer

YS Yellow Swordfish
Yellow Swordfish
Member

Yes – I don’t see why not. And I assume you are referring to the forum view.
Whose avatar though?

AT Alex T
Alex T
Member

Yellow Swordfish said
Yes – I don’t see why not. And I assume you are referring to the forum view.
Whose avatar though?

Yes, sorry I meant forum view.  Each user who starts a thread.  How would I go about doing this?

YS Yellow Swordfish
Yellow Swordfish
Member

In Reboot you will need to edit the spForumViewDesktop.php template in the theme folders or – in other themes the spForumView,php template. Preferably add the template to your child theme and edit that.

Look for the display function named sp_TopicIndexIcon() and comment it out. It is about two-thirds of the way down the file.

Underneath the commented out function add the following call:

sp_UserAvatar('tagClass=spRowIcon spLeft&context=user', $spThisTopic->first_user_id);

and that will display the avatar of the user who started the topic.

This will, of course, remove all use of custom icons so it will no longer show when new, unread posts have been made to a forum

AT Alex T
Alex T
Member

Yellow Swordfish said
In Reboot you will need to edit the spForumViewDesktop.php template in the theme folders or – in other themes the spForumView,php template. Preferably add the template to your child theme and edit that.

Look for the display function named sp_TopicIndexIcon() and comment it out. It is about two-thirds of the way down the file.

Underneath the commented out function add the following call:

<br />

sp_UserAvatar('tagClass=spRowIcon spLeft&context=user', $spThisTopic->first_user_id);

<br />

and that will display the avatar of the user who started the topic.

This will, of course, remove all use of custom icons so it will no longer show when new, unread posts have been made to a forum

OK, that worked.  I had to edit in the directory as it does not show up in the theme editor.  Is there a way to remove the avatar when there’s a new post in the thread and use another file?

MP Mr Papa
Mr Papa
Member

yeah, unfortunately, the editor wasn’t designed to go more than one level deep in the theme…  reboot is the first to do so…

AT Alex T
Alex T
Member

Mr Papa said
yeah, unfortunately, the editor wasn’t designed to go more than one level deep in the theme…  reboot is the first to do so…

Yea, threw me off at first…  Is there a way to add a “new” to the mod Yellow provided here?  Also, this works once in the forum, however on the preview when you’re in the main index for the forum it still shows up with the old file I had there.  The users avatars do not show up there.  

YS Yellow Swordfish
Yellow Swordfish
Member

Is there a way to add a “new” to the mod Yellow provided here? 

We do not have any built in way or method available. It’s a custom change not something we support with built in code.

Also, this works once in the forum, however on the preview when you’re in the main index for the forum it still shows up with the old file I had there.  The users avatars do not show up there.  

We changed the forum view template. That IS the index of topics in a forum… SO afraid I don’t understand your question.

AT Alex T
Alex T
Member

I meant in the unread and recently updated topics which is in the main forum list at the bottom. 

What do you guys use when you inspect a page?  How do you know where something is, lets say a php file?  I have notepad++ to open php file locally (i’m modding an overlay), however i’m not sure where I can find it when i’m inspecting a page using firebug.  I make the color changes with firebug and then I make the change in the php file to upload it, however I do have trouble finding where it is in the actual file. 

IK Ike
Ike
Member

When you say ‘How do you know where something is, lets say a php file?’, do you mean a php file? Or a rule within a php file?

We mostly use browser tools such as firebug, or a browser default inspector. It’s not always obvious where something is, especially as everything builds into one list so the ‘line’ is always wrong. But if you inspect something, you can always select the #ID and class above the rule you want to change, copy it, press control+f in notepad++ and search for it in the stylesheet (in this case reboot.php) if that helps.

Additionally, if you’re working on a custom overlay, the overlay variables are called by the stylesheet. It’s probably best to work from reboot.php as that will match up with the CSS you’re inspecting, and when you’re looking at the right class, you should see the overlay variable that’s being used. You can then open the overlay, find the variable and change the rule.

AT Alex T
Alex T
Member

Ike said
When you say ‘How do you know where something is, lets say a php file?’, do you mean a php file? Or a rule within a php file?

We mostly use browser tools such as firebug, or a browser default inspector. It’s not always obvious where something is, especially as everything builds into one list so the ‘line’ is always wrong. But if you inspect something, you can always select the #ID and class above the rule you want to change, copy it, press control+f in notepad++ and search for it in the stylesheet if that helps.

Yea, thanks…I mostly figured it out.  Much easier to use Chrome’s dev tools and notepad++ to make changes. 

IK Ike
Ike
Member

It’s definitely worth finding one you like using! Personally get on best with FF inspector but mainly because it’s the one I’m used to so I’m quick with it.

If you start playing around with mobile, Chrome is definitely the way to go. Hands down it has the best responsive design view I’ve used, and no need for extra plugins for things like user agents as they come included.

YS Yellow Swordfish
Yellow Swordfish
Member

And if you have a Mac, debugging iPhone and iPad display becomes possible as you can cnnect it to the OSX Safari and use the Safari web console. Neat.

AT Alex T
Alex T
Member

Would it be possible to move the “new” location next to the group break, yet still keep the forum avatars where I currently have them??

YS Yellow Swordfish
Yellow Swordfish
Member

Can you explain what you mean by ‘group break’?