Support Forum

Advanced Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
themes-topic
Modify Last Post Section in Group View
Avatar
Moggle
Member
Free Members
sp_UserOfflineSmall Offline
Feb 21, 2012 - 8:53 am

First of all, thank you for the wonderful plugin.  It is exactly what I am looking for.

Using the latest version.

Currently working on the theme and modifying the template files.

Just a couple of things:

  1. If there are no posts/topics, I would like a message to display in the Group View, i.e. "No topics/posts" in the last poster section.  Currently, it is just a blank box which doesn't look right.
  2. How do I move the topic/post title to be above the username?  So instead of: by user, post title, date/time, I would like post title, by user, date/time.  At the moment, the template in GroupView has "sp_ForumIndexLastPost" and the parameters, however there isn't a way to change how it is displayed.  Will I need to use different tags?

If you need any more information, then feel free to as.

Avatar
Yellow Swordfish
Glinton, England
SP Master
sp_UserOfflineSmall Offline
Feb 21, 2012 - 11:15 am

At the moment you can not actually influence either of those through the templates which is a bit remiss of us. They are both valid requests and I will open a ticket on these to get them done.

andy-signature.png
YELLOW
SWORDFISH
Avatar
Moggle
Member
Free Members
sp_UserOfflineSmall Offline
Feb 22, 2012 - 2:40 am

Thank you for replying and thank you again for this wonderful plugin.

Avatar
Yellow Swordfish
Glinton, England
SP Master
sp_UserOfflineSmall Offline
Feb 22, 2012 - 6:24 am

You're welcome.

andy-signature.png
YELLOW
SWORDFISH
Avatar
Moggle
Member
Free Members
sp_UserOfflineSmall Offline
Feb 22, 2012 - 7:36 am

Rather than creating another post for the last poster column, is there a way to display the last poster's avatar?  I've used the useravatar tag, but it doesn't display the correct avatar.  Instead it was showing the guest avatar on the sections which had no posts and no avatar is displayed where there is last poster info.

Avatar
Yellow Swordfish
Glinton, England
SP Master
sp_UserOfflineSmall Offline
Feb 22, 2012 - 3:31 pm

how are you doing that?

andy-signature.png
YELLOW
SWORDFISH
Avatar
Moggle
Member
Free Members
sp_UserOfflineSmall Offline
Feb 23, 2012 - 3:48 am

I'll try to explain it as best as I can:

If I used the following code:

sp_UserAvatar('tagClass=spImg spLeft&size=30&context=user');

I get this:
http://i43.tinypic.com/dd04e8.jpg
which is incorrect as the blank last post section should not display an avatar. The two users should have their own avatars displays.

Even if I change the context to current, it will display the same avatar instead of guest avatar.
Basically I would like something similar to how the recentposts widget displays the avatar.

I know some people do not want to display the avatar in groupview or forum view, so an option to turn it on or off will be great.

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Feb 23, 2012 - 7:27 am

if you set context=user, you have to pass a second argument telling us what user... ie

sp_UserAvatar('tagClass=spImg spLeft&size=30&context=user', $userid);

current would not be right as thats the current user viewing the page...  so

$spThisTopic->first_user_id

or

$spThisTopic->last_user_id

in place of the $userid in my code above...

Avatar
Moggle
Member
Free Members
sp_UserOfflineSmall Offline
Feb 23, 2012 - 9:34 am

The code above works fantastic in Forum View, however does not seem to work with Group View. I'm sure i'm missing something to allow it to work in Group View.

Avatar
Yellow Swordfish
Glinton, England
SP Master
sp_UserOfflineSmall Offline
Feb 23, 2012 - 9:59 am

It's quite a bit more complicated in spGroupView as it depends on whether you are showing the last post from the main forum or if it can include the last post from a subforum.

if the main forum you would use $spThisForum->user_id

if from a sub forum you would use $spThisForum->user_id_sub

The problem is that there is no current way of determining in the template which might be used. That is something we could consider trying to make more exposed I guess.

andy-signature.png
YELLOW
SWORDFISH
Forum Timezone: Europe/Stockholm
Most Users Ever Online: 1170
Currently Online:
Guest(s) 1
Currently Browsing this Page:
1 Guest(s)
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