vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=236)
-   -   Social Group and Album Enhancements - Add Last Poster to Social Groups list (https://vborg.vbsupport.ru/showthread.php?t=204352)

Lynne 02-04-2009 10:00 PM

Add Last Poster to Social Groups list
 
1 Attachment(s)
For some reason the lastposter is not shown on the Social Groups list. To add it, open the socialgroups_grouplist_bit template and find these lines:

HTML Code:

            $group[lastpostdate]
            <if condition="!$show['detailedtime']">
                <br /><span class="time">$group[lastposttime]</span>
            </if>

ADD right underneath:

HTML Code:

            <br />by <a href="member.php?$session[sessionurl]u=$group[lastposterid]">$group[lastposter]</a>
That's it!


edit: There is a cool idea from Mark.B in post 7:
Quote:

Originally Posted by Mark.B (Post 1769152)
Add this to the end of Lynne's code to get a "Go To Last Post" link too...
Code:

<a title="$vbphrase[go_to_last_post]" href="group.php?$session[sessionurl]do=discuss&gmid=$group[lastgmid]#gmessage$group[lastgmid]"><img class="inlineimg" src="$stylevar[imgdir_button]/lastpost.gif" border="0" /></a>
Note there is a space at the very start.


UKBusinessLive 02-05-2009 05:17 PM

Thanks Lynne, a Great 1 minute mod :D

Blackhat 02-06-2009 07:06 PM

Did you do something else too because my group listings does not look like your screenshot at all even without the "last poster" bit.

Theater 02-07-2009 07:04 AM

Maybe they should have put you in charge of the Social Group display, Lynne. Thank you and installed.

Lynne 02-07-2009 04:45 PM

Quote:

Originally Posted by Blackhat (Post 1736399)
Did you do something else too because my group listings does not look like your screenshot at all even without the "last poster" bit.

I'm pretty sure I didn't do anything. That is the full group list at group.php?do=grouplist

DieselMinded 03-08-2009 03:31 AM

/me installs Very Nice

Mark.B 03-15-2009 10:57 PM

Add this to the end of Lynne's code to get a "Go To Last Post" link too...
Code:

<a title="$vbphrase[go_to_last_post]" href="group.php?$session[sessionurl]do=discuss&gmid=$group[lastgmid]#gmessage$group[lastgmid]"><img class="inlineimg" src="$stylevar[imgdir_button]/lastpost.gif" border="0" /></a>
Note there is a space at the very start.

wtb 03-16-2009 12:17 AM

Cool idea Mark, thanks!

Lynne 03-16-2009 03:17 AM

Quote:

Originally Posted by Mark.B (Post 1769152)
Add this to the end of Lynne's code to get a "Go To Last Post" link too...
Code:

<a title="$vbphrase[go_to_last_post]" href="group.php?$session[sessionurl]do=discuss&gmid=$group[lastgmid]#gmessage$group[lastgmid]"><img class="inlineimg" src="$stylevar[imgdir_button]/lastpost.gif" border="0" /></a>
Note there is a space at the very start.

Great idea, Mark! I hope you don't mind, but I added your post to the first post in this thread so people don't accidentally overlook your idea.

Mark.B 03-16-2009 05:59 PM

Quote:

Originally Posted by Lynne (Post 1769312)
Great idea, Mark! I hope you don't mind, but I added your post to the first post in this thread so people don't accidentally overlook your idea.

Sure, that's fine.

Jasem 03-16-2009 07:13 PM

Good work, thanks!...

s8glive 04-23-2009 03:35 PM

anyone know how to add a link to the last post?

Mark.B 04-23-2009 10:11 PM

Three posts up....

s8glive 04-23-2009 10:15 PM

no like show a worable link.

Lynne 04-23-2009 11:06 PM

Quote:

Originally Posted by s8glive (Post 1797781)
no like show a worable link.

You need to explain yourself better. The link does 'work'. So if you want it to work some other way, you need to explain how that is.

LOKIN510051 04-26-2009 07:08 AM

Muchas Gracias Aunque No Se Ven Las Imagenes De Los Frupos Me Imaginoq Ue Es Falla Del Mismo Vbulletin Haber Si Hayt Solucion

Phantasmagoric 04-27-2009 10:12 AM

Nice little extra, thanks Lynne

Canadians360 09-08-2009 12:43 AM

Simple, neat, works like a charm, should have been a default for the social group list displays.

Love your work for social groups, they really take social groups from a nice feature to a great one.

EidolonAH 09-09-2009 04:42 AM

Brilliant, I am using the social groups in-place of buying the blog mod on Nurture, this little extra is perfect, thank you for the share.

Canadians360 09-09-2009 06:03 PM

1 Attachment(s)
[/HTML]
Quote:

Originally Posted by s8glive (Post 1797781)
no like show a worable link.

I think he may have been looking for a setup like this perhaps...

Find as before this following code...
HTML Code:

$group[lastpostdate]
            <if condition="!$show['detailedtime']">
                <br /><span class="time">$group[lastposttime]</span>
            </if>


But this time add the following code ABOVE...
HTML Code:

<a href="group.php?$session[sessionurl]do=discuss&amp;gmid=$group[lastgmid]#gmessage$group[lastgmid]" style="white-space:nowrap" title="$vbphrase[go_to_last_post]"><strong>$group[trimdiscussion]</strong></a><br />
This adds a linked name of the last discussion's title to the discussion in the group list.

@Lynne: hope you dont mind I posted this.

Screenshot attached bellow.

Lynne 09-09-2009 06:23 PM

I don't mind at all. I didn't understand his question, so I couldn't help him.

Xencored 09-24-2009 08:56 PM

Thanks Lynne Great mod :up:

Tom Kagan 10-07-2009 07:43 PM

Installed.

I suppose others might also want to go all the way with this formatting idea and make it exactly match the other areas with similar info. Instead of the above, try the following:

Replace the entire block. Remove everything between and including:
Code:

        <if condition="$show['lastpostinfo']">
and it corresponding ending:
Code:

        </if>

Then, replace it with the following:
Code:

        <if condition="$show['lastpostinfo']">
                        <div style="text-align: $stylevar[left]">
                                $group[lastpostdate]
                                <if condition="!$show['detailedtime']">
                                        <span class="time">$group[lastposttime]</span>
                                </if>
                        </div>
                        <if condition="$group['lastposterid']">
                                <div style="text-align: $stylevar[right]">
                                <phrase 1="member.php?$session[sessionurl]u=$group[lastposterid]" 2="$group[lastposter]">$vbphrase[by_x]</phrase>
                                        <a href="group.php?$session[sessionurl]do=discuss&amp;gmid=$group[lastgmid]#gmessage$group[lastgmid]"><img class="inlineimg" src="$stylevar[imgdir_button]/lastpost.gif" alt="$vbphrase[go_to_last_post]" border="0" /></a>
                        </div>
                    </if>
        <else />
                <div style="text-align: $stylevar[left]">
                        <div style="text-align: $stylevar[left]">
                                $vbphrase[group_created]
                        </div>
                        $group[lastpostdate]
                        <if condition="!$show['detailedtime']">
                                <span class="time">$group[lastposttime]</span>
                        </if>
                </div>
        </if>


This will give the information the same text alignment as similar blocks in other templates and also matches the presentation for the create date of the group if there are no messages to display. Additionally, it uses the standard phrases instead of hard coding "by" in the template.


All times are GMT. The time now is 10:05 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01206 seconds
  • Memory Usage 1,774KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (6)bbcode_code_printable
  • (4)bbcode_html_printable
  • (6)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (23)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete