Support Forum
Modify Last Post Section in Group View
Moggle
Member
Free Members
Offline
That's fantastic, the first code worked as I don't have any sub forums at the moment. I may do in the future.
Thank you so much. The support here has been fantastic!!!!
edit: just need to work out how to get rid of the guest icons where there are no topics/posts in the forum.
Moggle
Member
Free Members
Offline
Ok, i'm probably missing something here.
I have the following code:
sp_UserAvatar('tagClass=spAvatarGroup spLeft&size=30&link=none&context=user', $spThisForum->user_id);
which displays the avatars of the last poster but with the guest icon:
If I add the =0 after user_id, it changes all the avatars to the guest icon.
If a forum has no topics/posts, then technically it shouldn't display anything at all.
Yellow Swordfish
Glinton, England
SP Master
Offline
That's great. You could simplify this even further and remove the empty echo statement by using a not equals instead of an equals:
if ($spThisForum->user_id != 0) sp_UserAvatar('tagClass=spAvatarGroup spLeft&size=30&link=none&context=user', $spThisForum->user_id);
which will do the same thing.
YELLOW
SWORDFISH
|
Forum Timezone: Europe/Stockholm
Most Users Ever Online: 1170
Currently Online:
Guest(s) 1
Top Posters:
Mr Papa: 19448
Ike: 2086
Brandon: 864
kvr28: 804
jim: 650
FidoSysop: 577
Conrad_Farlow: 531
fiddlerman: 358
Stefano Prete: 325
Member Stats:
Guest Posters: 620
Members: 17365
Moderators: 0
Admins: 4
Forum Stats:
Groups: 7
Forums: 17
Topics: 10128
Posts: 79626