I want to create 3 different lists of 3 different content types. They should be displayed in one block and this block would be the only one in a particular region.

Ultimately I just want a title for this region or block respectively like news and inside three different news columns like sports, politics, business (just examples).

My ideas:

  1. A Block view using fields with three attachments. Problem is I can't create an empty block view without any fields specified. But then I have this extra SQL Query and the result will be rendered in html anyway even if I mark it "exclude from display".
  2. Create three different block views, assign them to the region and create a custom theme template for this region.

Are there other options. Panels? Haven't used it yet, so not sure if it would be a fit for this problem.

  • 1
    I'd go with option 2, but it depends on way too many factors to reliably answer. I can think of at least 3 other ways, but they only make sense in very specific situations - and we don't know your situation.
    – Mołot
    Commented Jan 14, 2016 at 10:54

2 Answers 2

  1. Create your first list as the block view itself and give it a title of "News".
  2. Now add the other two lists as attachments to the block view and set the titles to be blank.
  3. Finally, add a "Global: Text area" to the Header of each display, containing your "Sports", "Politics" and "Business" titles, perhaps inside <h3> tags.

Morbid's answer is good or you could look at https://www.drupal.org/project/blockgroup

However, depending on your needs, this could be the easiest and would perform best.

Add a filter to only allow the three content types. Then add the content type as an "excluded field" so it doesn't show. In the view settings, group by content type.

This will separate your nodes by type and if you have the various fields set to not show if empty, could definitely be the most manageable option.

Not the answer you're looking for? Browse other questions tagged or ask your own question.