Go Back   vb.org Archive > vBulletin 4 Discussion > vB4 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 12-08-2011, 12:23 AM
HMBeaty's Avatar
HMBeaty HMBeaty is offline
 
Join Date: Sep 2005
Posts: 4,141
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Confusing issue with the sidebar

Not sure where else to look for this, but I've managed to get the default vBulletin sidebar added to forumdisplay and showthread by using 2 plugins and some minor edits to the forumdisplay and showthread templates (no file edits now ).

Everything worked just fine when I was doing everything via file and template edits, but now that I've moved the file edits to the plugin system, I ran into a.....very odd issue lol.

If in vBulletin Options, I set Store CSS Stylesheets as Files? to No, everything looks as it should. However, if I set Store CSS Stylesheets as Files? to Yes, the sidebar goes all crazy



The contents of both plugins are pretty much the same and I'm using the hook locations forumdisplay_complete and showthread_complete...
PHP Code:
$specialtemplates = array(
    
'activeblocks'
);

$globaltemplates = array(
    
'block_blogentries',
    
'block_cmsarticles',
    
'block_newposts',
    
'block_sgdiscussions',
    
'block_tagcloud',
    
'block_threads',
    
'block_html',
    
'tag_cloud_link'
);

cache_templates($specialtemplates$style['templatelist']);
cache_templates($globaltemplates$style['templatelist']);

// ### SIDEBAR #################################################
$show['sidebar'] = false;
// disable blocks for ie6
if ($vbulletin->options['enablesidebar'] AND !(is_browser('ie') AND !is_browser('ie'7)) AND !VB_API)
{
    require_once(
DIR '/includes/class_block.php');
    
$blockmanager vB_BlockManager::create($vbulletin);
    
$sidebar $blockmanager->getSidebarHTML();
    if (
$sidebar)
    {
        
$show['sidebar'] = true;
    }

    
$show['sidebarposition'] = vB_Template_Runtime::fetchStyleVar($vbulletin->options['sidebarposition'] == 'left' 'right');
}

vB_Template::preRegister('SHOWTHREAD',array('sidebar' => $sidebar)); 
Also, the css has been added to both templates...

SHOWTHREAD
Code:
FIND:
{vb:cssfile toolsmenu.css,postlist.css,showthread.css,postbit.css,options.css,attachment.css,poll.css,lightbox.css}
REPLACE WITH:
{vb:cssfile toolsmenu.css,postlist.css,showthread.css,postbit.css,options.css,attachment.css,poll.css,lightbox.css,sidebar.css,tagcloud.css,widgets.css}

FIND:
<!--[if lt IE 8]>{vb:cssfile toolsmenu-ie.css,postlist-ie.css,showthread-ie.css,postbit-ie.css,poll-ie.css}<![endif]-->
REPLACE WITH:
<!--[if lt IE 8]>{vb:cssfile toolsmenu-ie.css,postlist-ie.css,showthread-ie.css,postbit-ie.css,poll-ie.css,sidebar-ie.css}<![endif]-->

FORUMDISPLAY
Code:
FIND:
{vb:cssfile toolsmenu.css,forumbits.css,forumdisplay.css,threadlist.css,options.css}
REPLACE WITH:
{vb:cssfile toolsmenu.css,forumbits.css,forumdisplay.css,threadlist.css,options.css,sidebar.css,tagcloud.css,widgets.css}

FIND:
{vb:cssfile toolsmenu-ie.css,forumbits-ie.css,forumdisplay-ie.css,threadlist-ie.css,options-ie.css}
REPLACE WITH:
{vb:cssfile toolsmenu-ie.css,forumbits-ie.css,forumdisplay-ie.css,threadlist-ie.css,options-ie.css,sidebar-ie.css}
So now I'm at a loss as to why when I turn on Store CSS Stylesheets as Files?, it gets thrown off. Any ideas?
Attached Images
File Type: jpg sidebar.jpg (72.4 KB, 0 views)
Reply With Quote
  #2  
Old 12-08-2011, 02:26 AM
kh99 kh99 is offline
 
Join Date: Aug 2009
Location: Maine
Posts: 13,185
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Have you checked for css files not loading or having errors? I usually use the error console in Firefox (although it's been so long I can't remember if it's an add-on or a standard feature).
Reply With Quote
  #3  
Old 12-08-2011, 02:28 AM
Max Taxable's Avatar
Max Taxable Max Taxable is offline
 
Join Date: Feb 2011
Posts: 3,134
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I just checked it and it all looks fine, did you fix this issue already?
Reply With Quote
  #4  
Old 12-08-2011, 02:48 AM
HMBeaty's Avatar
HMBeaty HMBeaty is offline
 
Join Date: Sep 2005
Posts: 4,141
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Max Taxable View Post
I just checked it and it all looks fine, did you fix this issue already?
No. I set Store CSS Stylesheets as Files? back to No

--------------- Added [DATE]1323316588[/DATE] at [TIME]1323316588[/TIME] ---------------

I set it back to No if anyone wants to take a look again

--------------- Added [DATE]1323317209[/DATE] at [TIME]1323317209[/TIME] ---------------

Hmm, I think I found the issue . Looking at the templates again....

FORUMDISPLAY
HTML Code:
    <vb:if condition="$vboptions['storecssasfile']">
        {vb:cssfile forumdisplay-rollup.css}
    <vb:else />
        {vb:cssfile toolsmenu.css,forumbits.css,forumdisplay.css,threadlist.css,options.css,sidebar.css,tagcloud.css,widgets.css}
    </vb:if>
SHOWTHREAD
HTML Code:
    <vb:if condition="$vboptions['storecssasfile']">
        {vb:cssfile showthread-rollup.css}
    <vb:else />
        {vb:cssfile toolsmenu.css,postlist.css,showthread.css,postbit.css,options.css,attachment.css,poll.css,lightbox.css,sidebar.css,tagcloud.css,widgets.css}
    </vb:if>
When I change
HTML Code:
{vb:cssfile forumdisplay-rollup.css}
To
HTML Code:
{vb:cssfile forumdisplay-rollup.css,sidebar.css,tagcloud.css,widgets.css}
And change
HTML Code:
{vb:cssfile showthread-rollup.css}
To
HTML Code:
{vb:cssfile showthread-rollup.css,sidebar.css,tagcloud.css,widgets.css}
It works again. Which still has me confused because I thought xxxxxxx-rollup.css already included all that other stuff
Reply With Quote
Reply


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 01:56 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.03529 seconds
  • Memory Usage 2,233KB
  • Queries Executed 12 (?)
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_code
  • (6)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
  • (4)post_thanks_box
  • (4)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (4)post_thanks_postbit_info
  • (4)postbit
  • (1)postbit_attachment
  • (4)postbit_onlinestatus
  • (4)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_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_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete