Support Forum

Last post avatar

< 1 2
Raven
Member
Jan 13, 2015 - 7:36 am

Okay here are some examples again:

spGroupView.php template.edit picture

22.pngImage Enlarger

Then this is where the code styles at but now its a guest avatar?

12.pngImage Enlarger

Yellow Swordfish
Glinton, England
Member
Jan 13, 2015 - 7:54 am

Sorry - forgot about that!

Instead of:

$spThisTopic->last_user_id

you will need:

$spThisForum-<user_id

We can also stop it appearing when there are no topics and help with the styling. I need to go out for half an hour but will come back on those issues as soon as I can.

Raven
Member
Jan 13, 2015 - 8:08 am

Okay take your time no rush. I also will need a custom forum design created to match my main wordpress site. So i will give some examples for that. Thanks for your help.

Raven
Member
Jan 13, 2015 - 8:58 am

@mr-papa 

@yellow-swordfish 

 

Okay here is what I did so far, and im happy on the outcome! Thanks for your help & time guys!

Template edit in sp.GroupView.php

sp_UserAvatar('tagClass=spPostUserAvatar spCenter&context=user&size=25',
$spThisForum->user_id);

example picture here

groupview.pngImage Enlarger

 

Then this is the outcome of the avatar placement:

forumindex2.pngImage Enlarger

Yellow Swordfish
Glinton, England
Member
Jan 13, 2015 - 9:18 am

If you want to avoid showing an avatar on forums with no topics then this should work:

if ( $spThisForum->post_count == true ) {
    sp_UserAvatar( ‘tagClass=spPostUserAvatar spCenter&context=user&size=25′, $spThisForum->user_id );
}

And if you are happy with them centred and the way they look now then great.

I will get Ike to contact you regarding theme customisation later today.

Raven
Member
Jan 13, 2015 - 9:28 am

@yellow-swordfish 

 

Thanks for the extra code. I may use it for future purposes. Looking forward to hearing from ike to get a new theme rolling! have a great day & take care.

Mr Papa
Simi Valley, CA
Member
Free Members
Jan 13, 2015 - 9:03 pm

good news! thanks for the update...

< 1 2