Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions
  #1  
Old 09-21-2006, 10:11 AM
Dannyboy1 Dannyboy1 is offline
 
Join Date: Aug 2005
Posts: 45
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default vertical navigation on left as on Sitepoint

If I want to make such a vertical navigation on left as on Sitepoint how can I do that? I mean I have tested the mods that I found here, but there are not even close to what you see on SItepoint.

Any ideas?
Reply With Quote
  #2  
Old 09-21-2006, 02:43 PM
MRGTB MRGTB is offline
 
Join Date: Dec 2004
Posts: 548
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

That's basically just a Left Side Column hack, which you can find here:

https://vborg.vbsupport.ru/showthread.php?t=117988
Reply With Quote
  #3  
Old 09-21-2006, 04:01 PM
Dannyboy1 Dannyboy1 is offline
 
Join Date: Aug 2005
Posts: 45
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
That's basically just a Left Side Column hack
Thanks....but I doubt that will make the navigation as on SitePoint beacuse do you see how you can add there subforum etc. I am not sure that you can do that with this mod, as long as I read the description. And that's for 3.6.0
I still use 3.5.4

Any other ideas?

Basically where from the vbulletin source can I grab the forum folder tree including all the subforums and just paste it in some custom column on the left?
Reply With Quote
  #4  
Old 10-09-2006, 12:35 AM
Adrian Schneider's Avatar
Adrian Schneider Adrian Schneider is offline
 
Join Date: Jul 2004
Posts: 2,528
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Here is what I'm using... It's not perfect yet, but it's pretty close.
PHP Code:
function buildForumTree($forumid = -1$depth 0$collapseDepth 1)
{
    global 
$vbulletin;
    
    
$forumbits '';
    foreach (
$vbulletin->forumcache as $forum)
    {
        
$permissions fetch_permissions($forum['forumid']);
                
        if (
            
$forum['depth'] != $depth or
            
$forum['parentid'] != $forumid or (
                !(
$permissions $vbulletin->bf_ugp_forumpermissions['canviewothers']) and
                !
$vbulletin->options['showprivateforums']
            )            
        ) continue; 
                    
        
$forum['childArray'] = explode(','$forum['childlist']);
        
$forum['subforums'] = count($forum['childArray']);
        
        
$show['collapsesubforums'] = ($depth == $collapseDepth and $forum['subforums'] > 2);
                
        
$childForumBits = ($forum['subforums'] > ?  
            
buildForumTree($forum['forumid'], $depth 1)
            : 
'' 
        
);

        eval(
'$forumbits .= "' fetch_template('portal_forumsbit') . '";');
    }
    
    return 
$forumbits;
}

$forumbits buildForumTree(); 
portal_forums
HTML Code:
<table width="180" cellspacing="$stylevar[cellspacing]" cellpadding="$stylevar[cellpadding]" border="0" class="tborder">
    <tr>
        <td class="thead">Forum Tree</td>
    </tr>
$forumbits
</table>
portal_forumsbit
HTML Code:
<if condition="$depth == 0">
    <tr>
        <td class="alt1">
            <span class="smallfont">
                <if condition="$show['collapsesubforums']">
                    <a style="float:$stylevar[right]" href="#" onclick="return toggle_collapse('forumtree_$forum[forumid]')">
                        <img id="collapseimg_forumtree_$forum[forumid]" src="images/buttons/collapse_alt_collapsed.gif" alt="Hide/Show" border="0" />
                    </a>
                <else />
                    &raquo;
                  </if>
                <strong><a href="forumdisplay.php?$session[sessionurl]f=$forum[forumid]">$forum[title]</a></strong>
            </span>
            <if condition="$show['collapsesubforums']"><div id="collapseobj_forumtree_$forum[forumid]" style="display: none"></if>
            $childForumBits
            <if condition="$show['collapsesubforums']"></div></if>
        </td>
    </tr>
<else />
    <div class="smallfont" style="margin-left: 10px; margin-top: 8px">
        <if condition="$show['collapsesubforums']">
            <a style="float:$stylevar[right]; padding-left: -13px" href="#" onclick="return toggle_collapse('forumtree_$forum[forumid]')">
                <img id="collapseimg_forumtree_$forum[forumid]" src="images/buttons/collapse_alt_collapsed.gif" alt="Hide/Show" border="0" />
            </a>
        <else />
            &raquo;&nbsp;
          </if>
        <a href="forumdisplay.php?$session[sessionurl]f=$forum[forumid]">$forum[title]</a>
        <if condition="$show['collapsesubforums']"><div id="collapseobj_forumtree_$forum[forumid]" style="display: none"></if>
        $childForumBits
        <if condition="$show['collapsesubforums']"></div></if>
    </div>
</if>
Reply With Quote
  #5  
Old 10-09-2006, 09:30 AM
Dannyboy1 Dannyboy1 is offline
 
Join Date: Aug 2005
Posts: 45
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks SirAdrian I will test your code today and report back.
Can you just be a littile bit more specific where do I have to paste the code provided by you?
Thank you.
Reply With Quote
  #6  
Old 10-15-2006, 08:50 AM
Hornstar Hornstar is offline
 
Join Date: Jun 2005
Location: Australia
Posts: 2,469
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

A demo of what yours looks like as well would be nice
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 09:23 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.05256 seconds
  • Memory Usage 2,228KB
  • Queries Executed 13 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (2)bbcode_html
  • (1)bbcode_php
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (6)post_thanks_box
  • (6)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (6)post_thanks_postbit_info
  • (6)postbit
  • (6)postbit_onlinestatus
  • (6)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete