vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.5 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=113)
-   -   Forums arranged in columns on forumhome (https://vborg.vbsupport.ru/showthread.php?t=99829)

Lionel 04-16-2009 08:51 PM

Quote:

Originally Posted by kairev (Post 1781487)
This is what I'm trying to accomplish:

http://www.hockeyforum.com

See how each team is listed in different categories (Atlantic Division, Northeast Division, Southeast Division, etc). It looks like a subforum of a subforum, almost. How can I do this? The only thing I'm able to get going here is columns for the first set of subforums...but those subforums have subforums too. ie my first set of subforums would be labeled Atlantic Division, Northeast Division, Southeast Division. I have all the teams set as subforums of those...but they aren't showing up on the main forum. I attached a screenshot of what I get...

Can anyone please help?

it's very easy.

First you set the main forum which will hold the subforums, you set how many columns you want, then you get the forumid

then you edit the template
Quote:

forumhome_forumbit_level1_nopost
you look for:

Quote:

<table style="border: none; width: 100%;">

$childforumbits
</table>
and depending of the amount column that you set, this is how many <td that you put. For example for 3 columns, you would place the red in your template, replacing xx with the main forumid

Quote:


<table style="border: none; width: 100%;">
<if condition="$forum[forumid]=='xx'">
<tr><td class="thead">Column 1 Title</td><td class="thead">Column 2 Title</td><td class="thead">Column 3 Title</td></tr>
</if>

$childforumbits
</table>
then in admincp you simply arrange the subforums order so they display in the proper column.

You might want to add some css in the td to give them some padding

legion! 04-24-2009 03:06 AM

this is the error i get wen i try to install on 3.81

Fatal error: Field subforumcolumns is not defined in $validfields in class vb_datamanager_forum in [path]/includes/class_dm.php on line 485

Lionel 04-24-2009 03:13 AM

This works just fine up to 3.82. You need to import the product and do the file edit, and you'll be fine.

belindazhu 06-11-2009 03:08 AM

don't work on 3.8.1, the error is: Parse error: syntax error, unexpected T_STRING in /home/content/j/s/e/******/html/forum/includes/functions_forumlist.php on line 273

You should make updation to 3.8.x.

belindazhu 06-12-2009 12:38 AM

Quote:

Originally Posted by rapidphim (Post 1650761)
Veccy, it's OK... I can live with that. However, do you know how am I going to get:

1/ the latest post info lie right beneath the forum title as in this website?
http://www.nbadimensions.net/forums/

2/ and how/where I can remove the "Thread/Post" so that only left "The latest post" and move number of post a side
http://www.nbadimensions.net/forums/

3/ also, it does not show the number of member/guest view on the forum anymore .... can we put it back?

Thanks so much.

Hi Rapidphim,

I saw your forum, this hack showing very good on your forum 3.8.2, I am admiring.

I think many people admire that, you pass through it.

So could you please share with us how did you do on 3.8.x? I met problems after do as Xenon tell us, the error is: Parse error: syntax error, unexpected T_STRING in /home/content/j/s/e/******/html/forum/includes/functions_forumlist.php on line 273

1. Copy your code here in "/includes/functions_forumlist.php" to me compeletely, ok?
2. Copy your code here in "forumhome_forumbit_level1_nopost", is it ok?

We need you.

JMEWLS` 06-18-2009 02:48 AM

how do I show moderators? I've put in the code but it puts me as a moderator:

http://www.nbadimensions.net/forums/

Look under team forums.

JMEWLS` 06-19-2009 05:57 AM

Bump.

JMEWLS` 06-21-2009 03:34 AM

anyone willing to help?

JMEWLS` 06-22-2009 10:39 AM

Anyone see a problem in the code?

functions_forumlist.php
PHP Code:

<?php


// ###################### Start construct_forum_columns #######################
function construct_forum_columns($parentid$columncount)
{
    global 
$vbulletin$stylevar$vbphrase$show;
    global 
$imodcache$lastpostarray$counters$inforum;

    
// this function takes the constant MAXFORUMDEPTH as its guide for how
    // deep to recurse down forum lists. if MAXFORUMDEPTH is not defined,
    // it will assume a depth of 2.

    
if ($columncount == 0)
    {
        
// 0 Columns means don't show subforums at all
        
return '';
    }

    
// call fetch_last_post_array() first to get last post info for forums
    
if (!is_array($lastpostarray))
    {
        
fetch_last_post_array();
    }

    if (empty(
$vbulletin->iforumcache["$parentid"]))
    {
        return;
    }

    if (!
defined(MAXFORUMDEPTH))
    {
        
define('MAXFORUMDEPTH'1);
    }

    
$forumbits '';

    
$counter 0;
    foreach (
$vbulletin->iforumcache["$parentid"] AS $forumid)
    {
        
// grab the appropriate forum from the $vbulletin->forumcache
        
$forum $vbulletin->forumcache["$forumid"];
        
$lastpostforum $vbulletin->forumcache["$lastpostarray[$forumid]"];
        if (!
$forum['displayorder'] OR !($forum['options'] & $vbulletin->bf_misc_forumoptions['active']))
        {
            continue;
        }

        
$forumperms $vbulletin->userinfo['forumpermissions']["$forumid"];
        
$lastpostforumperms $vbulletin->userinfo['forumpermissions']["$lastpostarray[$forumid]"];
        if (!(
$forumperms $vbulletin->bf_ugp_forumpermissions['canview']) AND !$vbulletin->options['showprivateforums'])
        { 
// no permission to view current forum
            
continue;
        }

        if (
$subsonly)
        {
            
$childforumbits construct_forum_bit($forum['forumid'], 1$subsonly);
        }
        else if (
$depth MAXFORUMDEPTH)
        {
            
$childforumbits construct_forum_bit($forum['forumid'], $depth$subsonly);
        }
        else
        {
            
$childforumbits '';
        }

        
// do stuff if we are not doing subscriptions only, or if we ARE doing subscriptions,
        // and the forum has a subscribedforumid
        
if (!$subsonly OR ($subsonly AND !empty($forum['subscribeforumid'])))
        {

            
$GLOBALS['forumshown'] = true// say that we have shown at least one forum

            
if (($forum['options'] & $vbulletin->bf_misc_forumoptions['cancontainthreads']))
            { 
// get appropriate suffix for template name
                
$tempext '_post';
            }
            else

            {
                
$tempext '_nopost';
            }

            if (!
$vbulletin->options['showforumdescription'])
            { 
// blank forum description if set to not show
                
$forum['description'] = '';
            }

            
// dates & thread title
            
$lastpostinfo $vbulletin->forumcache["$lastpostarray[$forumid]"];

            
// compare last post time for this forum with the last post time specified by
            // the $lastpostarray, and if it's less, use the last post info from the forum
            // specified by $lastpostarray
            
if ($vbulletin->forumcache["$lastpostarray[$forumid]"]['lastpost'] > 0)
            {
                if (!(
$lastpostforumperms $vbulletin->bf_ugp_forumpermissions['canview']) OR (!($lastpostforumperms $vbulletin->bf_ugp_forumpermissions['canviewothers']) AND $lastpostinfo['lastposter'] != $vbulletin->userinfo['username']))
                {
                    
$forum['lastpostinfo'] = $vbphrase['private'];
                }
                else
                {
                    
$lastpostinfo['lastpostdate'] = vbdate($vbulletin->options['dateformat'], $lastpostinfo['lastpost'], 1);
                    
$lastpostinfo['lastposttime'] = vbdate($vbulletin->options['timeformat'], $lastpostinfo['lastpost']);
                    
$lastpostinfo['trimthread'] = fetch_trimmed_title($lastpostinfo['lastthread']);

                    if (
$icon fetch_iconinfo($lastpostinfo['lasticonid']))
                    {
                        
$show['icon'] = true;
                    }
                    else
                    {
                        
$show['icon'] = false;
                    }

                    
$show['lastpostinfo'] = (!$lastpostforum['password'] OR verify_forum_password($lastpostforum['forumid'], $lastpostforum['password'], false));

                    eval(
'$forum[\'lastpostinfo\'] = "' fetch_template('forumhome_lastpostby') . '";');
                }
            }
            else if (!(
$forumperms $vbulletin->bf_ugp_forumpermissions['canview']))
            {
                
$forum['lastpostinfo'] = $vbphrase['private'];
            }
            else
            {
                
$forum['lastpostinfo'] = $vbphrase['never'];
            }

            
// do light bulb
            
$forum['statusicon'] = fetch_forum_lightbulb($forumid$lastpostinfo$forum);
            
$show['customstatusicon'] = false;
if (
$forum['hasstatusicons'])
{
    
$show['customstatusicon'] = true;
    if (
$forum['statusicon'] == 'new')
    {
        
$forum['customicon'] = $forum['statusiconon'];
    }
    if (
$forum['statusicon'] == 'new_lock')
    {
        
$forum['customicon'] = $forum['statusiconlockon'];
    }
    if (
$forum['statusicon'] == 'old')
    {
        
$forum['customicon'] = $forum['statusiconoff'];
    }
    if (
$forum['statusicon'] == 'old_lock')
    {
        
$forum['customicon'] = $forum['statusiconlockoff'];
    }
    if (
$forum['statusicon'] == 'link')
    {
        
$forum['customicon'] = $forum['statusiconlink'];
    }
}

            
// add lock to lightbulb if necessary
            
if ((!($forumperms $vbulletin->bf_ugp_forumpermissions['canpostnew']) OR !($forum['options'] & $vbulletin->bf_misc_forumoptions['allowposting'])) AND $vbulletin->options['showlocks'] AND !$forum['link'])
            {
                
$forum['statusicon'] .= '_lock';
            }

            
// get counters from the counters cache ( prepared by fetch_last_post_array() )
            
$forum['threadcount'] = $counters["$forum[forumid]"]['threadcount'];
            
$forum['replycount'] = $counters["$forum[forumid]"]['replycount'];

            
// get moderators ( this is why we needed cache_moderators() )
            
if ($vbulletin->options['showmoderatorcolumn'])
            {
                
$showmods = array();
                
$listexploded explode(','$forum['parentlist']);
                foreach (
$listexploded AS $parentforumid)
                {
                    if (!isset(
$imodcache["$parentforumid"]))
                    {
                        continue;
                    }
                    foreach(
$imodcache["$parentforumid"] AS $moderator)
                    {
                        if (isset(
$showmods["$moderator[userid]"]))
                        {
                            continue;
                        }

                        (
$hook vBulletinHook::fetch_hook('forumbit_moderator')) ? eval($hook) : false;

                        
$showmods["$moderator[userid]"] = true;
                        if (!isset(
$forum['moderators']))
                        {
                            eval(
'$forum[\'moderators\'] = "' fetch_template('forumhome_moderator') . '";');
                        }
                        else
                        {
                            eval(
'$forum[\'moderators\'] .= ", ' fetch_template('forumhome_moderator') . '";');
                        }
                    }
                }
                if (!isset(
$forum['moderators']))
                {
                    
$forum['moderators'] = '';
                }
            }

            if (
$forum['link'])
            {
                
$forum['replycount'] = '-';
                
$forum['threadcount'] = '-';
                
$forum['lastpostinfo'] = '-';
            }
            else
            {
                
$forum['replycount'] = vb_number_format($forum['replycount']);
                
$forum['threadcount'] = vb_number_format($forum['threadcount']);
            }

            if ((
$subsonly OR $depth == MAXFORUMDEPTH) AND $vbulletin->options['subforumdepth'] > 0)
            {
                
$forum['subforums'] = construct_subforum_bit($forumid, ($forum['options'] & $vbulletin->bf_misc_forumoptions['cancontainthreads'] ) );
            }
            else
            {
                
$forum['subforums'] = '';
            }

            
$children explode(','$forum['childlist']);
            foreach(
$children AS $childid)
            {
                
$forum['browsers'] += ($inforum["$childid"] ? $inforum["$childid"] : 0);
            }

            if (
$depth == AND $tempext == '_nopost')
            {
                global 
$vbcollapse;
                
$collapseobj_forumid =& $vbcollapse["collapseobj_forumbit_$forumid"];
                
$collapseimg_forumid =& $vbcollapse["collapseimg_forumbit_$forumid"];
                
$show['collapsebutton'] = true;
            }
            else
            {
                
$show['collapsebutton'] = false;
            }

            
$show['forumsubscription'] = ($subsonly true false);
            
$show['forumdescription'] = ($forum['description'] != '' true false);
            
$show['subforums'] = ($forum['subforums'] != '' true false);
            
$show['browsers'] = ($vbulletin->options['displayloggedin'] AND !$forum['link'] AND $forum['browsers'] ? true false);

            
// build the template for the current forum
            
$column_width intval(100 $columncount) . '%';
            eval(
'$column = "' fetch_template("forumhome_forumbit_columncell") . '";');
            
            
// do the columnstuff
            
if ($counter $columncount == 0)
            {
                
// Begin a new row
                
$forumbits .= "\t<tr>\n";
            }
            
$forumbits .= $column;
            if (
$counter $columncount == $columncount 1)
            {
                
// End row
                
$forumbits .= "\t</tr>\n";
            }
            
$counter++;
        }
    }

    
// prevent unclosed <tr> tags
    
if ($counter $columncount != 0)
    {
        
$forumbits .= "\t</tr>\n";
    }
    
    return 
$forumbits;
}


Carpetsmoker 06-22-2009 10:54 PM

Asking the same question four times will not get you an answer sooner, please do not keep asking the same question over and over.

JMEWLS` 06-23-2009 11:17 AM

Well, I don't exactly see what harm it does? It brings my post into the new posts section in which users can see and potentially help me. No ones going to view an old thread?

JMEWLS` 06-24-2009 08:20 PM

Bump

lordtopcat 06-24-2009 11:12 PM

Notice that the modification was made for the 3.5 system and if you read you will notice it says: Not Supported up the top.

JMEWLS` 06-26-2009 05:06 AM

Quote:

Originally Posted by lordtopcat (Post 1836743)
Notice that the modification was made for the 3.5 system and if you read you will notice it says: Not Supported up the top.

So the modification just stuffs up the moderators in 3.8?

It's fine with everything else.

Blackheart_72 06-27-2009 05:38 PM

Quote:

Originally Posted by JMEWLS` (Post 1831662)
how do I show moderators? I've put in the code but it puts me as a moderator:

http://www.nbadimensions.net/forums/

Look under team forums.

I am having the same problem at the moment, shows my moderators including myself.

If i can work it out will post up.

JMEWLS` 07-01-2009 12:01 AM

Thankyou, I can't seem to find it. It's weird.

trinity9 07-05-2009 06:17 PM

1. Imported product-xenon_forumcols.xml through admincp, imported fine.

2. Edited functions_forumlist.php via ftp and did the edits detailed in the instructions.

3. I added the "Add This New Function" above the footer description box at the very end of the functions_forumlist.php file.

4. Uploaded edited functions_forumlist.php back to my forum.

Then, when I went to check my forums (I still have another edit to do in templates,) each time I get a invalid compression error box on white screen with my forums totally inactive.

I am using 3.5.4 and do have other modifications including cyb-subforum mod.

Another note, in my forums edit, the box to Show Subforums in # of columns does appear.

I have re-inserted a brand new .php file to get my forums up and running, yet would like to get this hack active.

Any help would be appreciated.

adamskiii 07-28-2009 02:35 PM

Can someone please help me install this on Vbulletin 3.8.3

maddento 07-31-2009 01:01 AM

Quote:

Originally Posted by adamskiii (Post 1857182)
Can someone please help me install this on Vbulletin 3.8.3

Same here please. Willing to pay a good lump of money to do so as well

anestetic 09-16-2009 07:58 PM

for 3.8.x ???? please

Blackheart_72 09-16-2009 09:42 PM

The hack works on 3.8 peeps, got it on my forum.

What problems are you having ?

anestetic 09-19-2009 08:00 PM

functon_forumlist.php don't work
please your code function_forumlist.php and template edit code see

your forum is wonderfull ...

Allan 09-19-2009 08:52 PM

But work perfectly on vB 3.8.4.

anestetic 09-20-2009 01:40 PM

my forum version 3.8.2

Blackheart_72 09-24-2009 03:44 PM

Has anyone managed to get it to show the private text when its a private forum, i have looked in templates for the text but cant find $vbphrase[private] anywhere.

At the moment it just shows nothing.

Verionia 09-25-2009 08:55 PM

Quote:

Originally Posted by Allan (Post 1887734)
But work perfectly on vB 3.8.4.

How did you get it to work... doesnt work for me. Did you press save Active Status after?

concepts 10-15-2009 09:00 AM

Just followed the instructions.. made a few template edits so I can still use the DIFF ICON for each category (currently not using a diff though)... and followed the instruction in this post..
got it working on a heavily MODDED 3.8.4

See it Working HERE

writerkimba 10-16-2009 10:54 PM

Hey,

I've just gone through the thread and managed to get the subforum columns working on my forum with Veccy's edit in the forumdisplay.php file. However, there is a slight issue where I'm getting an extra few columns at the end. I even did the edit in the level one no post file but still no joy.

How do I get rid of them?

rice 10-27-2009 11:56 PM

is there anyone on this board that is willing to give a proper short synopsis on what to do to get this done right now. trying to do it like basketballforum.com but a different subject. please please please

thanks very much in advance

rice 11-10-2009 05:24 PM

awesome thanks :)

heywho 12-09-2009 09:11 PM

Has anyone tried this hack w the forums in vB4 Publishing? yet

I'm testing beta 4.04 and would be interested to know if there are any "gotcha's"

Strike3ForumsMH 02-18-2010 11:18 AM

I'm also curious if anyone has got this to work in vB4. (I haven't yet tried myself.)

bobster65 02-18-2010 01:19 PM

Quote:

Originally Posted by Strike3ForumsMH (Post 1985524)
I'm also curious if anyone has got this to work in vB4. (I haven't yet tried myself.)

Hey Mish, I think someone explained how to do this via CSS. You may want to check in the vb4 area and do a little searching. Think it might have been Lynne. Not sure if it will work for you or not.

Strike3ForumsMH 02-18-2010 06:32 PM

Quote:

Originally Posted by bobster65 (Post 1985590)
Hey Mish, I think someone explained how to do this via CSS. You may want to check in the vb4 area and do a little searching. Think it might have been Lynne. Not sure if it will work for you or not.

Hey man, nice to see you again. :)

I'll check that out though, thanks!

French2 02-22-2010 07:04 PM

2 columns and icons for every forum

I have iinstalled different icons for each forum (via different icons in "statusicon etc").
Now I have anslo installed zhe addon "Forum arranged in columns". I works- I get my forums 2 columns. But, unfortunedly the new individual icons that I had installed, have disappeared and I see only the usual icons.

What could I do?

rice 06-22-2010 09:16 PM

anyone have any luck with this for 4???

thanks

kishorprins 04-17-2011 12:18 PM

IF anyone is interested, https://vborg.vbsupport.ru/showthread.php?t=228484 ;it is the VB 4 version. Just a simple css edit :).

Wonksta 04-23-2011 11:16 PM

This works flawlessly in 3.8.6 Patch Level 1.

Big big thanks goes out to Veccy for sharing his knowledge and code for the cell etc, you're the man!

MagicThemeParks 04-24-2011 04:08 AM

Works on 3.8.7 with a few tweaks. :up:

Demo here: United States History Forum

Still customizing and adding the status icons, but so far so good! :D

Wonksta 04-24-2011 05:03 AM

Quote:

Originally Posted by MagicThemeParks (Post 2187996)
Works on 3.8.7 with a few tweaks. :up:

Demo here: United States History Forum

Still customizing and adding the status icons, but so far so good! :D

Looks good!

I personally removed the Post stats, much much cleaner that way IMO.


All times are GMT. The time now is 11:43 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.01890 seconds
  • Memory Usage 1,977KB
  • 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
  • (1)bbcode_php_printable
  • (12)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete