Hello.
I'm trying to add a div in a custom box. I think populating my box with fields but for the hcard format I'd need a surrouding div with classes for the infos to be parsed...
How or where can I add a div to a special block type ? Is it possible to create a template for a custom block ?
SHould I create a module ?
Any idea really welcome...

Comments

artatum’s picture

Well I got one track : edit the template.php of my theme and into preprocess_block I added :
my box id is 'block-boxes-my-hcard' so I'm trying :

  $block_id = $vars['block']->module . '-' . $vars['block']->delta;
   switch ($block_id) {
    case 'boxes-my-hcard':
      $vars['classes_array'][] = 'vcard';      
      break;
    case 'block-17':
      $vars['classes_array'][] = 'vcard'; 
      break;
  }

On a normal block like block-17 it works. But not on my Box...
If someone see how we can add a class onto a Box-block, any idea is welcome...