I am trying to keep most of the configuration in code (and separating content and configuration). When I have a panel that is supposed to contain a content from for example a node, I would like to be able to export that setup somehow so that I can be sure it would work also on the other page. So it shouldnt be a node id, not either node title (so from my point of view, this help doesnt qualify).

The way I did it is somewhat complicated, but allows me to keep all config in code while happily creating the content separately. I am posting a writeup my colleague did to convince me i am doing it too much complicated. Yet, I cant think of a better way.

  1. Create taxonomy vocabulary with terms: top, middle, bottom.
  2. Create custom node-type called panel content to which you assign terms from vocabulary from pt 1
  3. Create a view that takes term from vocab from pt 1 as an argument.
  4. Place this view inside frontpage panel and hardcode the argument depending on region.

Am I missing some point here? Would there be a better way to it? Thanks.

  • Unfortunately I don't entirely see how your solution allows you to embed specific nodes?
    – Letharion
    Nov 21 '12 at 14:08
  • step 2 could have been a nodetype with taxonomy, for some reason i used entities in that project. So to answer your question - specific node would be selected by taxonomy.
    – mojzis
    Nov 21 '12 at 16:48

One could

  1. Use Fieldable panels panes, which can replace the custom entity you use, and put content directly into the pane.
  2. Configure the view to find nodes with a certain tag. Tag the node that should show up. Require the tag to be uniquely applied if only a single node is allowed.

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.