3

Up until now, I've always used content panes provided by Views in Panels to accomplish tasks like "Related content" and "Additional information about ABC." I just realized that Views also provides an attachment display, which as far as I can tell seems to be similar to a content pane except it doesn't require Panels.

However, if I'm already using Panels, are there any use cases where I would be better off using an attachment instead of a content pane, or are these basically the same thing?

3

There may some cases where an attachment is more useful than a content pane, but I always go with content panes by default.

  1. Split content panes allow easier reuse of the View. You can show the View by itself in a second location, and make minor overrides with a second display.
  2. You can easily have individual Pane settings. Caching, style, visibility rules etc.

I think the case in general for attachments would be if a second view absolutely depends on a first one. If they would never make sense individually, then one could might as well "combine them" into one, although the benefits are fairly limited, such as "move only one pane in the UI".

| improve this answer | |
4

Attachments can inherit the exposed filters of the display they are attached to.

| improve this answer | |
  • I could be wrong here, but I don't see any reason why that couldn't be equally true for content panes. – Letharion Apr 3 '14 at 10:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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