Hello Drupal Folk,

I am just creating a drupal site and had a thought cross my mind.

Is it good or bad etiquette to use a block on drupal if it is only being placed into one page?

I'm going to do that method to put something in the sidebar, but interested to know if that would be frowned upon by those in the big leagues.

Have a ponder and let me know your thoughts.
Cheers

Comments

ryivhnn’s picture

It's a website. Do what you want how you want as long as you're not writing too much non-compliant spaghetti code to do so ;) That is my opinion and I'm sticking to it :P

works at bekandloz | plays at technonaturalist

Drupalace-1’s picture

I don't see why a block on a single page would be intrinsically good or bad. If you have a need for some info to appear on only one page, and a block makes sense for its presentation, then go for it!

This is probably very common, actually - particularly, blocks appearing only on the front page. A welcome message, status message, etc. might be a good example.

--------
Easy Drupal Admin Manual, Drupal questions, other stuff for the newbie: http://www.drupalace.com

dman’s picture

One block on one page, of course, not a problem!

12 blocks doing similar things on 12 respective pages? You need to re-think your approach, eg http://drupal.org/project/sidecontent

Or for a several-to-several relationship, a bit of php logic may be more advanced.

.dan.
if you are asking a question you think should be documented, please provide a link to the handbook where you think the answer should be found.
| http://www.coders.co.nz/ |

bdiddymc’s picture

Cheers for the replies.

I've just been using the one block method, but had a pondering as to whether it would be better for future works to follow another route to be a "good" coder.

I know it's not the end of the world using the block, but just interested to hear your thoughts and if you opt to do it in another more efficient method.

thanks

nirvanajyothi’s picture

you may wanna check out blockreference module http://drupal.org/project/blockreference

It can be used to display the 'Disabled' blocks too