vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.7 Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=229)
-   -   Forum Home Enhancements - Alternative Forumhome Lastpost Display (https://vborg.vbsupport.ru/showthread.php?t=174922)

EWGF 04-01-2008 10:00 PM

Alternative Forumhome Lastpost Display
 
This tutorial changes the look of the last posted post in the forumhome template. The vertical column for the last posts disappears and a box with the last posted post appears below the forum description. Also see the included screenshot to get a better view of this mod.

History:
Version 1.0: First release.
Version 1.1: Added collapsable boxes.
Version 1.2: Fixed boxes for subforums.
Version 1.3: Fixed scrambled box without forum description, fixed box for no-posts forum, added missing "collapseimg" variable to lastpostby.gif, compatible with vBulletin 3.7.x.
Version 1.31: Small adjustment to the "forumhome_forumbit_level2_post" template.

Support only for people who've marked as installed.

Attachment 78123

bxbigt 04-02-2008 10:10 PM

Demo?

EWGF 04-02-2008 10:49 PM

Sorry, I have it only implanted on my testvb at the moment. But the screenshot is animated, so it gives a good impression of how it seems to work.

Barakat 04-05-2008 02:24 PM

works good ........

nice

Preech 04-05-2008 03:15 PM

Never mind, I didn't read the entire first post.

Meatshield 04-06-2008 09:32 PM

Could this be collaped by default?
and if so what edits do i have to make?
Thanks

glorify 04-07-2008 11:38 AM

Does this work well with category view? All the rest in the past haven't worked well at all.

EWGF 04-07-2008 12:24 PM

Quote:

Originally Posted by Meatshield (Post 1484708)
Could this be collaped by default?
and if so what edits do i have to make?
Thanks

Yes, that is possible. Note that visitors with javascript disabled, can't see the content of the by default collapsed box.

In forumhome_forumbit_level1_post and forumhome_forumbit_level2_post, search for:
Code:

<div id="collapseobj_forumhome_lastpostby_$forum[forumid]" class="smallfont" style="padding:6px; margin-top:6px; border: 1px solid #000000; $vbcollapse[collapseobj_forumhome_lastpostby]
Add after:
Code:

; display:none

Quote:

Originally Posted by glorify (Post 1485146)
Does this work well with category view? All the rest in the past haven't worked well at all.

It works fine now.

TCattitude 04-14-2008 02:15 AM

For last vBulletin 3.7.0 RC3 this search and remove in forumhome_forumbit_level2_post:
<td class="alt2" nowrap="nowrap">$forum[lastpostinfo]</td>

now is this:
<td class="alt2">$forum[lastpostinfo]</td>

Nice template mod, i like it!

YLP1 04-26-2008 09:56 PM

How do you change the background of the last post info to like alt2 or alt1? Thanks in advance.

ShadowOne 04-30-2008 12:20 PM

anyone to add this to the alternate posts and thread view?

Hams 05-05-2008 07:10 PM

Quote:

Originally Posted by TCattitude (Post 1490107)
For last vBulletin 3.7.0 RC3 this search and remove in forumhome_forumbit_level2_post:
<td class="alt2" nowrap="nowrap">$forum[lastpostinfo]</td>

now is this:
<td class="alt2">$forum[lastpostinfo]</td>

Nice template mod, i like it!

thanx .. alot

you are best :)

Raptor 06-20-2008 11:41 PM

how to change the style of the dark black border - say to a light gray dotted line ?

and how to change the background color of the last post info ?

Thanks in advance

EWGF 06-21-2008 09:03 PM

Quote:

Originally Posted by Raptor (Post 1555007)
how to change the style of the dark black border - say to a light gray dotted line ?

and how to change the background color of the last post info ?

Thanks in advance

Look into the bits

- forumhome_forumbit_level1_post
- forumhome_forumbit_level2_post

Code:

<div id="collapseobj_forumhome_lastpostby_$forum[forumid]" class="smallfont" style="padding:6px; margin-top:6px; border: 1px solid #000000; $vbcollapse[collapseobj_forumhome_lastpostby]" align="$stylevar[left]">$forum[lastpostinfo]</div>
Change the border: 1px solid #000000 into border: 1px dotted #555555. For the background; alter the smallfont-class used here, use another class which contains information for a backgroundcolor or just add background-color: pink to the above code.

Though it's more efficient to put it all into one class, instead of calling a class ?nd putting several other attributes after it. Small mistake from me of not doing so, but that's easy to alter. Could work on that, if people rather like that.

Quote:

Originally Posted by YLP1 (Post 1500144)
How do you change the background of the last post info to like alt2 or alt1? Thanks in advance.

Code:

<div id="collapseobj_forumhome_lastpostby_$forum[forumid]" class="smallfont" style="padding:6px; margin-top:6px; border: 1px solid #000000; $vbcollapse[collapseobj_forumhome_lastpostby]" align="$stylevar[left]">$forum[lastpostinfo]</div>
Change the bolded text into class="alt1" or class="alt2".

sdavis2702 06-22-2008 12:51 AM

Looks pretty good I like it. Once someone installs it, please shoot me a link of it. I'd like to see an entire forumhome page using this mod!

EWGF 06-22-2008 02:18 PM

Quote:

Originally Posted by sdavis2702 (Post 1555747)
Looks pretty good I like it. Once someone installs it, please shoot me a link of it. I'd like to see an entire forumhome page using this mod!

http://www.digital-forums.com/index.php

Thomas Dukic 06-24-2008 06:53 PM

Hi grate hack ( if i could not muck it up ) But as i just said i think i messed up. I would like to say am completely new to this so bare with me.

All was good untill i could not find the

Quote:

Search and remove:

----------

PHP Code:

<td class="alt2" nowrap="nowrap">$forum[lastpostinfo]</td

----------
Here is a copy of my forumhome_forumbit_level2_post where i think i went wrong:

PHP Code:

<tr align="center">
    <
td class="alt2"><img src="$stylevar[imgdir_statusicon]/$forum[imageprefix]forum_$forum[statusicon].gif" alt="" border="0" id="forum_statusicon_$forum[forumid]/></td>
    <
td class="alt1Active" align="$stylevar[left]id="f$forum[forumid]">
        <
div>
<
a style="float:$stylevar[right]href="#top" onclick="return toggle_collapse('forumhome_lastpostby_$forum[forumid]')"><img id="collapseimg_forumhome_lastpostby_$forum[forumid]src="$stylevar[imgdir_button]/collapse_thead$vbcollapse[collapseimg_forumhome_lastpostby].gif" alt="" border="0" /></a>
            <
a href="forumdisplay.php?$session[sessionurl]f=$forum[forumid]"><strong>$forum[title]</strong></a>
            <if 
condition="$show['browsers']"><span class="smallfont">(<phrase 1="$forum[browsers]">$vbphrase[x_viewing]</phrase>)</span></if>
        </
div>
        <if 
condition="$show['forumdescription']"><div class="smallfont">$forum[description]</div></if>
<
div id="collapseobj_forumhome_lastpostby_$forum[forumid]class="smallfont" style="padding:6px; margin-top:6px; border: 1px solid #000000; $vbcollapse[collapseobj_forumhome_lastpostby]align="$stylevar[left]">$forum[lastpostinfo]</div>
        <if 
condition="$show['forumsubscription']"><div class="smallfont"><strong><a href="subscription.php?$session[sessionurl]do=removesubscription&amp;f=$forum[forumid]rel="nofollow">$vbphrase[unsubscribe_from_this_forum]</a></strong></div></if>
        <if 
condition="$show['subforums']"><div class="smallfont" style="margin-top:$stylevar[cellpadding]px"><strong>$vbphrase[subforums]</strong>: $forum[subforums]</div></if>
    </
td>
    <
td class="alt2">$forum[lastpostinfo]</td>
    <
td class="alt1">$forum[threadcount]</td>
    <
td class="alt2">$forum[replycount]</td>
    <if 
condition="$vboptions['showmoderatorcolumn']">
    <
td class="alt1"><div class="smallfont">$forum[moderators]&nbsp;</div></td>
    </if>
</
tr>
$childforumbits 


I rely can not see where i went wrong. So if someone could please show me where i went wrong or what i should put in there to make it correct.

My forum is here if you do have a look the welcome section is correct as it is just displaying the number of threads

http://i207.photobucket.com/albums/b...redbyvBu-2.png

But the rest of the forum is still displaying this :

https://vborg.vbsupport.ru/external/2008/06/5.png

EWGF 06-25-2008 02:53 PM

They removed the "nowrap" in the latest version, forgot to edit the .txt file. So just look for the:
Code:

<td class="alt2">$forum[lastpostinfo]</td>
So it should look like this:
Code:

<tr align="center">
    <td class="alt2"><img src="$stylevar[imgdir_statusicon]/$forum[imageprefix]forum_$forum[statusicon].gif" alt="" border="0" id="forum_statusicon_$forum[forumid]" /></td>
    <td class="alt1Active" align="$stylevar[left]" id="f$forum[forumid]">
        <div>
<a style="float:$stylevar[right]" href="#top" onclick="return toggle_collapse('forumhome_lastpostby_$forum[forumid]')"><img id="collapseimg_forumhome_lastpostby_$forum[forumid]" src="$stylevar[imgdir_button]/collapse_thead$vbcollapse[collapseimg_forumhome_lastpostby].gif" alt="" border="0" /></a>
            <a href="forumdisplay.php?$session[sessionurl]f=$forum[forumid]"><strong>$forum[title]</strong></a>
            <if condition="$show['browsers']"><span class="smallfont">(<phrase 1="$forum[browsers]">$vbphrase[x_viewing]</phrase>)</span></if>
        </div>
        <if condition="$show['forumdescription']"><div class="smallfont">$forum[description]</div></if>
<div id="collapseobj_forumhome_lastpostby_$forum[forumid]" class="smallfont" style="padding:6px; margin-top:6px; border: 1px solid #000000; $vbcollapse[collapseobj_forumhome_lastpostby]" align="$stylevar[left]">$forum[lastpostinfo]</div>
        <if condition="$show['forumsubscription']"><div class="smallfont"><strong><a href="subscription.php?$session[sessionurl]do=removesubscription&amp;f=$forum[forumid]" rel="nofollow">$vbphrase[unsubscribe_from_this_forum]</a></strong></div></if>
        <if condition="$show['subforums']"><div class="smallfont" style="margin-top:$stylevar[cellpadding]px"><strong>$vbphrase[subforums]</strong>: $forum[subforums]</div></if>
    </td>
    <td class="alt1">$forum[threadcount]</td>
    <td class="alt2">$forum[replycount]</td>
    <if condition="$vboptions['showmoderatorcolumn']">
    <td class="alt1"><div class="smallfont">$forum[moderators]&nbsp;</div></td>
    </if>
</tr>
$childforumbits


Thomas Dukic 06-25-2008 03:40 PM

Thanks so much for your help !! All sorted now.

glorify 08-06-2008 02:12 AM

Changed the code a tad, but looks great here.


All times are GMT. The time now is 12:42 PM.

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.01883 seconds
  • Memory Usage 1,824KB
  • 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
  • (2)bbcode_php_printable
  • (7)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (20)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