vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   How can i hide the last post of a subforum? (https://vborg.vbsupport.ru/showthread.php?t=189719)

acast 09-01-2008 10:21 AM

How can i hide the last post of a subforum?
 
Hi friends, i want to hide the last post viewed from forumhome of one subforum. How can i do it? I look for it in the search button, but i didnt find it.

Thanks.

acast 09-07-2008 10:12 PM

I read that i have to put this, but i put it and it doesnt work:

<if condition="!in_array($forum['forumid'], array(1,2,3,6))"></if>

Dismounted 09-08-2008 05:39 AM

You actually have to put the code that should be shown or not shown in between the two conditional tags.

acast 09-08-2008 01:35 PM

Quote:

Originally Posted by Dismounted (Post 1617173)
You actually have to put the code that should be shown or not shown in between the two conditional tags.

Do you know which code is?

Dismounted 09-09-2008 01:42 AM

The column in one (or a few) of the forumhome_forumbit_* templates. I don't have a copyo f vBulletin in front of me right now.

acast 09-09-2008 05:06 AM

Quote:

Originally Posted by Dismounted (Post 1617900)
The column in one (or a few) of the forumhome_forumbit_* templates. I don't have a copyo f vBulletin in front of me right now.

I find this in forumhome_forumbit_level2_post:

Code:

</if>
        </td>
        <td class="alt2" nowrap="nowrap">$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>



I try something like that but it doesnt work:

Code:

<if condition="!in_array($forum['28'], nowrap="nowrap">$forum[lastpostinfo] array(28))"></if>
I cant put that code.

Sweeks 09-20-2008 10:09 AM

Tried the same code and gives an error straight away.

Code:

Parse error: syntax error, unexpected '=' in /public_html/root/includes/adminfunctions_template.php(3729) : eval()'d code on line 15
Here is the full code after editing:

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 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>
                <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>



<if condition="!in_array($forum['158'], nowrap="nowrap">$forum[lastpostinfo] array(158))"></if>

        <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

Any help on this would be really appreciated or a point in the right direction. Thank you
________
PUBLIC MOVIES

Lynne 09-20-2008 01:23 PM

This is the line you want to get rid of?
HTML Code:

<td class="alt2" nowrap="nowrap">$forum[lastpostinfo]</td>
How about:
HTML Code:

<td class="alt2" nowrap="nowrap"><if condition="$forum['forumid'] == '158'">&nbsp;<else />$forum[lastpostinfo]</if></td>
That should put a space/blank in if it is forumid 158, but it will show the lastpostinfo for all other forums. (I have not tried it.)

acast 09-21-2008 07:26 AM

Quote:

Originally Posted by Lynne (Post 1626351)
This is the line you want to get rid of?
HTML Code:

<td class="alt2" nowrap="nowrap">$forum[lastpostinfo]</td>
How about:
HTML Code:

<td class="alt2" nowrap="nowrap"><if condition="$forum['forumid'] == '158'">&nbsp;<else />$forum[lastpostinfo]</if></td>
That should put a space/blank in if it is forumid 158, but it will show the lastpostinfo for all other forums. (I have not tried it.)

It doesnt work, perhaps we are in the wrong place, and we only have to put a code in the forumhome template.

Sweeks 09-21-2008 09:52 AM

I have tried this too and it did not work.

I am having a problem where It is not showing the post amount or thread amount within the new sub forums I am creating too.

Basically what I am after is to be able to hide the last post info of two sub forums and still have the thread and post count to show to all. Also these forums are passworded too.

If anyone can help me achieve this I will be really grateful.

Thank you
________
Motorcycle Tires

Lynne 09-21-2008 02:35 PM

Quote:

Originally Posted by acast (Post 1626798)
It doesnt work, perhaps we are in the wrong place, and we only have to put a code in the forumhome template.

Instead of using $forum[forumid], try using $foruminfo[forumid]. Maybe that will work instead. (Also, try it with and without single quotes around "forumid". I always forget if it needs the quotes in there or not!)

Also, are you editing the correct template? Do this - vboptions > General Settings > Add Template Name in HTML Comments > set to Yes . Then go back to your page and view the source code and you will see the name of the template called around your part of the code.

acast 09-27-2008 12:26 PM

I did it with this code in forumhome:
<if condition="$show['lastpostinfo'] AND $forumid!=28">

anthroforum 12-09-2008 09:37 AM

I would like to know how to do this, but not replace with a blank space.

Instead, the last post column is filled by the latest post from one of the other sub-forums.


All times are GMT. The time now is 05:58 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.01630 seconds
  • Memory Usage 1,752KB
  • 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
  • (4)bbcode_code_printable
  • (4)bbcode_html_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (13)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