I've looked all over and can't find a solution to this. I understand you don't have to have titles for blocks in 4.7, but why do I have to have menu titles? I can't seem to find a way to hide them.

As an example, I don't want a title above my Primary Links to be shown. Likewise, the title of the user or "Navigation" for non-logged in users is useless. At the same time I don't want to remove all titles (by editing out the link in the block.tpl.php file) since I have some blocks that need titles.

Any help out there? Why don't menus just have descriptions like blocks which act as their administrative title? Or just a click option to hide the title?

Thanks for any help!
Andrew

Comments

nevets’s picture

Each block has a unique id, for example the block with your user name here on drupal has the id block-user-1, so you could write a rule like

#block-user-1 h2 {
display: none;
}

which would hide the title for that block. Is this what you are after?

halftone’s picture

It seems to be a common requirement. I'm using 4.6 and bodging menu headings and all h3 headings to be all lowercase in CSS. If you don't want any displayed you can use your theme's style.css file to set 'display: none;' for the appropriate contextual H3 classes.

Regards
Tony Sleep

DustyNine’s picture

Thanks for the advice - I've toyed with the CSS and didn't quite get it to work, but if that's the solution I'll go work on it some more.

smallbizpod’s picture

I've been struggling with what I think is the exact same issue and found a very useful way to display the content of a block i.e. in my case a custom menu without the title.

See the following: http://drupal.org/node/26502

Simply use this code to extract the block content you want based on its module and id, then position it anywhere in your page.tpl.php file, for example. Then simply style with CSS.

Worked for me, but I'm seriously no expert.

Cheers

AB

PS It's better than display:none which doesn't work terribly well in IE

droshani’s picture

Here what you need to do in Drupal 6x,

1. Go to Home › Administer › Site building › Blocks
2. Select to configure "Navigation"
3. In Block title, you just add <none> that will hide the title for the block