PDA

View Full Version : vb respecting drupals directives on what pages to show blocks?


Goddess
08-20-2007, 09:08 PM
i know i can work around this, but i wondered if it was by design or how it works or if i have something set up wrong.

i'm setting up blocks like recent blog posts, etc, and telling drupal to only display them on the front page - i.e. <front>. that works for the drupal side, but if there are drupal sidebars enabled in the forum, it shows all the blocks available even if it's only supposed to display on the front page. is that just how it works or am i missing something?

i'm using vbDrupal 5.2.0 RC1 but plan to upgrade soon.

elmuerte
08-25-2007, 04:58 AM
the forum environment is detected as <front>, I will address this in the next release

I will probably let the forum identify itself as <forum>/THIS_SCRIPT
Where THIS_SCRIPT is defined in each vBulletin script. This is usually the filename minus the extension.
So on a thread page the page will be identified by:
<forum>/showthread

Goddess
08-25-2007, 11:15 AM
oh! well that explains things! ok, thanks for letting me know how it works. and on a later release, then i know i will have a more fine-tuned control of the blocks. (and it will also allow me to put adsense on the forum side in blocks if i want without violating adsense tos...)

very cool.

thank you so much, elmuerte, for all your work on vbdrupal. it's was perfect for what i needed for this project, and i'm thrilled with all the stuff i can do with it.

Goddess
09-07-2007, 10:53 PM
the forum environment is detected as <front>, I will address this in the next release

I will probably let the forum identify itself as <forum>/THIS_SCRIPT
Where THIS_SCRIPT is defined in each vBulletin script. This is usually the filename minus the extension.
So on a thread page the page will be identified by:
<forum>/showthread

Ok, to use this, I assume I'm in the block configuration, using the visibility settings. Can I just call it like this, i.e. with <forum> like I would for the front page, or do i need to add it as some kind of php conditional? because, at least on my dev install, I'm not getting it to show the way i am expecting and I'm not sure if I'm doing it right or it's something else...i've been stirring up a bit of module soup over on the dev side so it's possible my data's toast and i need to restore a backup for further work...but before i jump to conclusions i want to make sure i'm clear on how it's supposed to work.

Goddess
09-09-2007, 04:59 PM
testing on my production install, and it's not my database. i suspect i may not be understanding how to call this because i haven't been able to get it to recognize, by configuring the block to show as on the example for the showthread page...

elmuerte
09-10-2007, 02:37 PM
hmm, looks like something went wrong. Not every change was included.
Quick fix:

edit the drupal/includes/vbdrupal/bootstrap.inc file
find: $_REQUEST['q'] = '<forum>/'. THIS_SCRIPT;
(shouldn't near line #63)
below that add: $_GET['q'] =& $_REQUEST['q'];
that will fix it (included in the next release)

silurius
09-11-2007, 03:59 PM
I am not seeing how to make blocks show up on forum content areas (e.g. forum/index.php, forum/forumdisplay.php, forum/showthread.php). My blocks are set to appear on every page and no pages are listed for exclusion.

What am I missing?

sifuhall
09-11-2007, 04:36 PM
I am not seeing how to make blocks show up on forum content areas (e.g. forum/index.php, forum/forumdisplay.php, forum/showthread.php). My blocks are set to appear on every page and no pages are listed for exclusion.

What am I missing?

To get the vbdrupal blocks inside your vbulletin forum, in your vbulletin admincp, under vbulletin options -> vbdrupal select yes to load blocks then select the blocks you would like to use (usually left, right, header, footer, content, etc.) Then in your vbulletin theme you can place the blocks where you like (for example, $drupal_blocks[left] will put the left block, etc.)

silurius
09-11-2007, 05:16 PM
I had an asterisk in that field (default setting) to begin with, and changed that to read left, right instead. Yet still my blocks do not show up on index, forumdisplay, or showthread. Something is obviously overriding the setting somehow, but I have no idea where to begin looking.

sifuhall
09-12-2007, 05:08 AM
In what vbulletin template did you include the $drupal_block statement?

silurius
09-12-2007, 10:29 AM
None, yet. Only just now did I finally notice this on the vbDrupal Options page itself:

The themed blocks will be available for vBulletin templates in the variable $drupal_blocks[region]. For example $drupal_blocks[left] for all the blocks on the left.

My bad! Is there a recommended placement?

I'd presumed that the code would already be in place and would show or not show blocks depending on the the Options page.

Edit: Experimenting with right-hand blocks anyway.

sifuhall
09-12-2007, 10:46 AM
Placement is really dependent on your vbulletin theme.

For this site (and most of my large sites) I create a table and place the left frame in the first td.

For one of my sites I'm just using the header block and using nicemenus in the header that works very well also.

silurius
09-12-2007, 11:33 AM
Not a problem, got it going. Thanks for the help!

Goddess
09-18-2007, 05:50 PM
that will fix it (included in the next release)

thank you!