View Full Version : Question, side panel?
CrazyEh
02-11-2006, 07:44 PM
I don't have cmps right now, I will in a few days. I have a quick question.. I've seen some people that are using cmps, and they have side panels while viewing the forum? :O does cmps offer that now? :O
ConqSoft
02-11-2006, 08:37 PM
http://www.vbadvanced.com/membersarea.php?do=viewusermanual&productid=4&pageid=6
CrazyEh
02-11-2006, 08:46 PM
Ahhhh I missed that.. thanks alot!.
Kirby
02-14-2006, 09:41 PM
If you are a bit creative, it also works without having to modify files ;)
Example: http://www.planet-liebe.de/vbb/index.php
ConqSoft
02-14-2006, 09:42 PM
Ok, spill it Kirby. I PM'd you the link to that other thread. :D
Brian
02-15-2006, 03:02 PM
If you are a bit creative, it also works without having to modify files ;)
Example: http://www.planet-liebe.de/vbb/index.php
I'd be interested to see how you're doing that too. From what I remember, there wasn't really a way to do it with plugins since those are pulled from the datastore...
Kirby
02-15-2006, 10:30 PM
First of all: My CMPS is kinda heavily modified.
I removed the 3 columns completely and replaced them with "location identifiers". One location is "sidebar"
I then got a Plugin like this on Hook style_fetch
if (!defined('VBA_PORTAL') AND (!$vbulletin->userinfo['userid'] OR ($vbulletin->userinfo['customuseroptions'] & $vbulletin->bf_misc_customuseroptions['showsidebar'])))
{
$show['sidebar'] = true;
define('VBA_PORTAL', true);
define('VBA_SCRIPT', 'CMPS');
define('VBA_PAGE', 'forum');
$pages = array('pageid' => X, 'type' => 'module', 'modules' => 'w,y,z', 'userperms' => 'a,b,c', 'advanced' => 'N;');
}
if (defined('VBA_PORTAL'))
{
require_once(DIR . '/includes/vba_cmps_include_top.php');
}
and this for parse_templates
if (defined('VBA_PORTAL'))
{
require_once(DIR . '/includes/vba_cmps_include_bottom.php');
}
if ($show['sidebar'] AND THIS_SCRIPT != 'adv_index')
{
if (!empty($home))
{
usort($home, 'order_mods');
foreach ($home AS $key => $blocks)
{
if ($blocks['location'] == 'sidebar')
{
$home['sidebarblocks'] .= $blocks['content'];
}
}
}
}
X is the pageid of my 'forum' page; y,y,z are the modules to be used for the sidebar; a,b,c are the usergroups that are allowed for this "page"
The modules are being set to show up in location sidebar.
I've then modified my templates header/footer templates to include $home[sidebarblocks] (if the user want's to have the sidebar)
This way, I can show it on all pages - without overhead for regex-stuff, querying the page, etc.
cmiller1014
03-05-2006, 04:33 PM
Brian,
Based on what Kirby has shown us here, can you show us how to do something similar with a standard VBA install? I am not good with PHP and since his is so heavily modified I wouldn't know where to begin with doing something like this.
Thanks in advance to anyone that can help!
vBulletin® v3.7.4, Copyright ©2000-2009, Jelsoft Enterprises Ltd.