PDA

View Full Version : Forums and galleries as module blocks


StewardManscat
12-25-2004, 09:16 AM
This thread (http://www.vbadvanced.com/forum/showthread.php?t=4157) talks about how to put cmps blocks on every forum/gallery page. But, if I understand it correctly, it will always be the same blocks. The content will not change according to forumid/page or gallery cat/page.

Is there any brilliant way to contain forum and gallery pages within cmps blocks, then let cmps drive the whole page?

Or somehow get cmps block contents into templates and use the forum/gallery style system to create pages according to forumid/page or gallery cat/page.

I'm looking for a true mish-mash of content. The page itself is made up of blocks. Each block is generated by either the forums, gallery, or a custom module.

I don't know who should be the "driver". Which system sits at the top-most level? CMPS, forum, or gallery? Or maybe I am simply asking too much.

Brian
12-25-2004, 09:58 PM
You could create separate pages, then use something like this at the top of your browseimages.php file:
if (isset($c))
{
$catid = $c;
}

switch($catid)
{
case 1:
define('VBA_PAGE', 'category1page');
break;
case 2:
define('VBA_PAGE', 'category2page');
break;
default:
define('VBA_PAGE', 'gallery_default');
}